diff --git a/tests/Integration/Database/EloquentHasOneOfManyTest.php b/tests/Integration/Database/EloquentHasOneOfManyTest.php index 45c049cabaa1..4be71d3e5da7 100644 --- a/tests/Integration/Database/EloquentHasOneOfManyTest.php +++ b/tests/Integration/Database/EloquentHasOneOfManyTest.php @@ -74,7 +74,7 @@ public function testItGetsCorrectResultUsingAtLeastTwoAggregatesDistinctFromId() $this->assertSame($user->oldest_updated_state->id, $oldestState->id); $this->assertSame($user->oldest_updated_oldest_created_state->id, $oldestState->id); - $users = User::with('latest_updated_state', 'latest_updated_latest_created_state')->all(); + $users = User::with('latest_updated_state', 'latest_updated_latest_created_state')->get(); $this->assertSame($users[0]->latest_updated_state->id, $latestState->id); $this->assertSame($users[0]->latest_updated_latest_created_state->id, $latestState->id);