Add --force flag to migrations (#1203)
This commit is contained in:
parent
4985da991b
commit
7d8a34645e
@ -82,7 +82,7 @@ class MigrationService extends Service
|
||||
// A little ugly, run the main migration first, this makes sure the migration table is there
|
||||
$output = '';
|
||||
|
||||
Artisan::call('migrate');
|
||||
Artisan::call('migrate', ['--force' => true]);
|
||||
$output .= trim(Artisan::output());
|
||||
|
||||
// Then get any remaining migrations that are left over
|
||||
|
@ -126,7 +126,7 @@ class ModuleService extends Service
|
||||
'enabled' => 1,
|
||||
]);
|
||||
|
||||
Artisan::call('module:migrate '.$module_name);
|
||||
Artisan::call('module:migrate '.$module_name, ['--force' => true]);
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -225,7 +225,7 @@ class ModuleService extends Service
|
||||
}
|
||||
|
||||
Artisan::call('config:cache');
|
||||
Artisan::call('module:migrate '.$module);
|
||||
Artisan::call('module:migrate '.$module, ['--force' => true]);
|
||||
|
||||
return flash()->success('Module Installed');
|
||||
}
|
||||
@ -246,7 +246,7 @@ class ModuleService extends Service
|
||||
]);
|
||||
|
||||
if ($status === true) {
|
||||
Artisan::call('module:migrate '.$module->name);
|
||||
Artisan::call('module:migrate '.$module->name, ['--force' => true]);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
@ -60,7 +60,7 @@ abstract class TestCase extends \Illuminate\Foundation\Testing\TestCase
|
||||
Notification::fake();
|
||||
|
||||
Artisan::call('database:create', ['--reset' => true]);
|
||||
Artisan::call('migrate:refresh', ['--env' => 'testing']);
|
||||
Artisan::call('migrate:refresh', ['--env' => 'testing', '--force' => true]);
|
||||
|
||||
// $this->disableExceptionHandling();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user