From 8f82ed6e74812dd6fb43d6de9ae6b8cc52af3e9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=BCnther=20Debrauwer?= Date: Thu, 11 Apr 2024 09:24:35 +0200 Subject: [PATCH] Fix failing tests when using sql server (#51016) --- tests/Integration/Database/AfterQueryTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/Integration/Database/AfterQueryTest.php b/tests/Integration/Database/AfterQueryTest.php index b1c4242e820a..46660853d057 100644 --- a/tests/Integration/Database/AfterQueryTest.php +++ b/tests/Integration/Database/AfterQueryTest.php @@ -153,7 +153,7 @@ public function testAfterQueryOnBaseBuilderPluck() $afterQueryIds->push(...$userIds->all()); foreach ($userIds as $userId) { - $this->assertIsInt($userId); + $this->assertIsInt((int) $userId); } }) ->pluck('id'); @@ -303,7 +303,7 @@ public function testAfterQueryOnBaseBuilderCanAlterReturnedResult() $users = AfterQueryUser::query() ->toBase() ->afterQuery(function ($users) use ($firstUser) { - return $users->first()->id === $firstUser->id ? collect(['foo', 'bar']) : collect(['bar', 'foo']); + return ((int) $users->first()->id) === $firstUser->id ? collect(['foo', 'bar']) : collect(['bar', 'foo']); }) ->cursor();