Fix tests

This commit is contained in:
Amine Ben hammou
2019-06-25 12:08:14 +01:00
committed by M. Shull
parent 5ae402bcab
commit 8fd19f1d68
2 changed files with 3 additions and 1 deletions

View File

@ -216,7 +216,8 @@ class MP2Migrator {
*
*/
private function eraseMP3Data() {
$activator = new Activator(new SettingsController());
$settings = new SettingsController();
$activator = new Activator($settings, new Populator($settings, WPFunctions::get()));
$activator->deactivate();
$activator->activate();

View File

@ -31,6 +31,7 @@ class WordPressTest extends \MailPoetTest {
$this->settings->set('cron_trigger', [
'method' => 'none',
]);
ScheduledTask::where('type', Beamer::TASK_TYPE)->deleteMany();
$this->_addScheduledTask(Beamer::TASK_TYPE, ScheduledTask::STATUS_SCHEDULED, Carbon::createFromTimestamp(current_time('timestamp') + 600));
}