Skip to content
This repository was archived by the owner on Aug 22, 2023. It is now read-only.

Commit 831485c

Browse files
GromNaNalcaeus
authored andcommitted
Test _id as array and object
1 parent c6e3f33 commit 831485c

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

tests/ModelTest.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -408,6 +408,20 @@ public static function provideId(): iterable
408408
$date,
409409
$date,
410410
];
411+
412+
$array = ['foo' => 'bar'];
413+
yield 'array' => [
414+
User::class,
415+
$array,
416+
$array,
417+
];
418+
419+
$object = (object) ['foo' => 'bar'];
420+
yield 'object' => [
421+
User::class,
422+
$object,
423+
$object,
424+
];
411425
}
412426

413427
public function testCustomPrimaryKey(): void

0 commit comments

Comments
 (0)