Skip to content

Commit

Permalink
fixup! IBX-6773: Bookmarks for non-accessible contents cause exception
Browse files Browse the repository at this point in the history
  • Loading branch information
vidarl committed Jun 27, 2024
1 parent 9c9b56e commit f620af5
Showing 1 changed file with 2 additions and 13 deletions.
15 changes: 2 additions & 13 deletions eZ/Publish/API/Repository/Tests/LocationServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -1987,19 +1987,8 @@ public function testBookmarksAreSwappedAfterSwapLocation()
$afterSwap = $bookmarkService->loadBookmarks();
/* END: Use Case */

$expectedIdsAfter = array_map(static function (Location $item) use ($demoDesignLocationId, $contactUsLocationId) {
if ($item->id === $demoDesignLocationId) {
return $contactUsLocationId;
}

return $item->id;
}, $beforeSwap->items);

$actualIdsAfter = array_map(static function (Location $item) use ($demoDesignLocationId, $contactUsLocationId) {
return $item->id;
}, $afterSwap->items);

$this->assertEquals($expectedIdsAfter, $actualIdsAfter);
$this->assertEquals($contactUsLocationId, $afterSwap->items[0]->id);
$this->assertEquals($beforeSwap->items[1]->id, $afterSwap->items[1]->id);
}

/**
Expand Down

0 comments on commit f620af5

Please sign in to comment.