From cfb9c766bd2c63131ae8727e730d5934a8e6f564 Mon Sep 17 00:00:00 2001 From: Bartek Wajda Date: Wed, 7 Aug 2024 09:38:19 +0200 Subject: [PATCH] IBX-8418: Fixed integration test --- .../Core/Repository/TrashService/TrashTest.php | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/tests/integration/Core/Repository/TrashService/TrashTest.php b/tests/integration/Core/Repository/TrashService/TrashTest.php index d34e7ebdbb..849745e17e 100644 --- a/tests/integration/Core/Repository/TrashService/TrashTest.php +++ b/tests/integration/Core/Repository/TrashService/TrashTest.php @@ -59,22 +59,13 @@ public function testTrashLocationDeletesChildrenDrafts(): void $trashService->trash($locationToTrash); - $draftIds = [ + $contentInfos = $contentService->loadContentInfoList([ $draft1->getId(), $draft2->getId(), $draft3->getId(), $draftSecondDepth->getId(), - ]; + ]); - foreach ($draftIds as $draftId) { - try { - $contentService->loadContentInfo($draftId); - $this->fail( - sprintf('Expected NotFoundException not thrown for draft ID = %d', $draftId), - ); - } catch (NotFoundException $e) { - self::assertInstanceOf(NotFoundException::class, $e); - } - } + self::assertEmpty($contentInfos); } }