File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed
workbench/database/factories Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change 1919use Illuminate \Foundation \Testing \RefreshDatabase ;
2020use Orchestra \Testbench \Concerns \WithWorkbench ;
2121use Orchestra \Testbench \TestCase ;
22- use Symfony \Component \Uid \Ulid ;
2322use Workbench \Database \Factories \AuthorFactory ;
2423use Workbench \Database \Factories \BookFactory ;
2524
@@ -88,8 +87,8 @@ public function testCreateBook(): void
8887 'author ' => 'api/authors/ ' .$ author ->id ,
8988 'isbn ' => fake ()->isbn13 (),
9089 'isAvailable ' => rand (0 ,1 ) === 1 ,
91- ]
92- ]
90+ ],
91+ ],
9392 ], ['accept ' => ['application/json ' ]]);
9493 $ response ->assertStatus (200 );
9594 $ data = $ response ->json ();
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ public function definition(): array
3737 'author_id ' => AuthorFactory::new (),
3838 'isbn ' => fake ()->isbn13 (),
3939 'publication_date ' => fake ()->optional ()->date (),
40- 'is_available ' => rand ( 0 , 1 ) === 1 ,
40+ 'is_available ' => 1 === random_int ( 0 , 1 ) ,
4141 'internal_note ' => fake ()->text (),
4242 ];
4343 }
You can’t perform that action at this time.
0 commit comments