From 7ce3082fa2385577958991991494c076800660da Mon Sep 17 00:00:00 2001 From: Duncan Sommerville Date: Wed, 15 Jul 2015 11:46:52 -0400 Subject: [PATCH] Fix upgrade being run from unit tests --- airtime_mvc/application/Bootstrap.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/airtime_mvc/application/Bootstrap.php b/airtime_mvc/application/Bootstrap.php index 4a5157f1e..f16183157 100644 --- a/airtime_mvc/application/Bootstrap.php +++ b/airtime_mvc/application/Bootstrap.php @@ -130,9 +130,9 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap protected function _initTasks() { /* We need to wrap this here so that we aren't checking when we're running the unit test suite */ - $taskManager = TaskManager::getInstance(); - $taskManager->runTask(AirtimeTask::UPGRADE); // Run the upgrade on each request (if it needs to be run) if (getenv("AIRTIME_UNIT_TEST") != 1) { + $taskManager = TaskManager::getInstance(); + $taskManager->runTask(AirtimeTask::UPGRADE); // Run the upgrade on each request (if it needs to be run) //This will do the upgrade too if it's needed... $taskManager->runTasks(); }