Skip to content

Commit da296d1

Browse files
authored
Merge pull request #11 from robindrost/patch-1
Use load migrations instead of publishing them.
2 parents 35ec047 + a069378 commit da296d1

File tree

3 files changed

+2
-7
lines changed

3 files changed

+2
-7
lines changed
File renamed without changes.

src/MagicLinkServiceProvider.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@ public function boot()
1717
__DIR__.'/../config/magiclink.php' => config_path('magiclink.php'),
1818
], 'config');
1919

20-
$this->publishes([
21-
__DIR__.'/../databases/migrations/create_table_magic_links.php' => database_path('migrations').'/2017_07_06_000000_create_table_magic_links.php',
22-
], 'migrations');
20+
$this->loadMigrationsFrom(__DIR__.'/../databases/migrations');
2321

2422
$this->loadRoutesFrom(__DIR__.'/routes.php');
2523
}

tests/TestCase.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,15 +59,12 @@ protected function getEnvironmentSetUp($app)
5959
*/
6060
protected function setUpDatabase($app)
6161
{
62+
$this->artisan('migrate');
6263
$app['db']->connection()->getSchemaBuilder()->create('users', function (Blueprint $table) {
6364
$table->increments('id');
6465
$table->string('email');
6566
});
6667

67-
include_once __DIR__.'/../databases/migrations/create_table_magic_links.php';
68-
69-
(new \CreateTableMagicLinks)->up();
70-
7168
User::create(['email' => '[email protected]']);
7269
}
7370

0 commit comments

Comments
 (0)