File tree Expand file tree Collapse file tree 2 files changed +31
-4
lines changed Expand file tree Collapse file tree 2 files changed +31
-4
lines changed Original file line number Diff line number Diff line change 1+ <?php
2+
3+ declare (strict_types=1 );
4+
5+ use Illuminate \Database \Migrations \Migration ;
6+ use Illuminate \Database \Schema \Blueprint ;
7+ use Illuminate \Support \Facades \Schema ;
8+
9+ return new class () extends Migration {
10+ public function up (): void
11+ {
12+ Schema::create ('users ' , function (Blueprint $ table ): void {
13+ $ table ->id ();
14+ $ table ->string ('name ' );
15+ $ table ->string ('email ' )->unique ();
16+ $ table ->timestamp ('email_verified_at ' )->nullable ();
17+ $ table ->string ('password ' );
18+ $ table ->rememberToken ();
19+ $ table ->timestamps ();
20+ });
21+ }
22+
23+ public function down (): void
24+ {
25+ Schema::dropIfExists ('users ' );
26+ }
27+ };
Original file line number Diff line number Diff line change 66
77use Illuminate \Foundation \Testing \LazilyRefreshDatabase ;
88use Laravelcm \Subscriptions \SubscriptionServiceProvider ;
9- use Orchestra \Testbench \Concerns \WithWorkbench ;
109use Orchestra \Testbench \TestCase as BaseTestCase ;
1110use Tests \Models \User ;
1211
1312abstract class TestCase extends BaseTestCase
1413{
1514 use LazilyRefreshDatabase;
16- use WithWorkbench;
1715
1816 protected function getPackageProviders ($ app ): array
1917 {
@@ -24,8 +22,10 @@ protected function getPackageProviders($app): array
2422
2523 protected function defineDatabaseMigrations (): void
2624 {
27- $ this ->loadLaravelMigrations ();
28- $ this ->loadMigrationsFrom (__DIR__ .'/../../database/migrations ' );
25+ $ this ->loadMigrationsFrom ([
26+ __DIR__ .'/../database/migrations ' ,
27+ __DIR__ .'/../../database/migrations ' ,
28+ ]);
2929 }
3030
3131 protected function getEnvironmentSetUp ($ app ): void
You can’t perform that action at this time.
0 commit comments