protected function setUp() { // \Zend_Application: loads the autoloader require_once 'Zend/Application.php'; // Create application, bootstrap, and run $application = new \Zend_Application(APPLICATION_ENV, GEMS_ROOT_DIR . '/configs/application.example.ini'); $this->bootstrap = $application; include_once GEMS_TEST_DIR . '/library/Gems/Cookies.php'; // Dirty fix for cookie problem during tests parent::setUp(); $this->bootstrap->bootstrap('db'); $this->bootstrap->getBootstrap()->getContainer()->db = $this->db; $this->bootstrap->bootstrap(); \Zend_Registry::set('db', $this->db); \Zend_Db_Table::setDefaultAdapter($this->db); $sourceSurveyId = 1; $language = 'en'; $lsDb = $this->db; $translate = $this->getTranslate(); $tablePrefix = ''; $this->fieldmap = new \Gems_Tracker_Source_LimeSurvey1m9FieldMap($sourceSurveyId, $language, $lsDb, $translate, $tablePrefix); }
/** * Tears down the fixture, for example, closes a network connection. * This method is called after a test is executed. */ protected function tearDown() { parent::tearDown(); }