espoTester->getApplication(true, $userName, $password, $clearCache); } /** * Get Espo Application * * @return \Espo\Core\Application */ protected function getApplication() { return $this->espoApplication; } /** * Get Espo container * * @return \Espo\Core\Container */ protected function getContainer() { return $this->getApplication()->getContainer(); } protected function setUp() { $params = array( 'dataFile' => $this->dataFile, 'pathToFiles' => $this->pathToFiles, 'className' => get_class($this), ); $this->espoTester = new Tester($params); $this->espoTester->initialize(); $this->beforeStartApplication(); $this->espoApplication = $this->createApplication($this->userName, $this->password); $this->afterStartApplication(); } protected function tearDown() { $this->espoTester->terminate(); $this->espoTester = NULL; $this->espoApplication = NULL; } protected function beforeStartApplication() { } protected function afterStartApplication() { } }