Example #1
0
 protected function setUp()
 {
     $this->_fixtureDir = __DIR__ . '/Performance/_files';
     $this->_fixtureConfigData = (require $this->_fixtureDir . '/config_data.php');
     $this->_installerScript = realpath($this->_fixtureDir . '/app_base_dir//dev/shell/install.php');
     $this->_config = new Magento_Performance_Config($this->_fixtureConfigData, $this->_fixtureDir, $this->_fixtureDir . '/app_base_dir');
     $this->_shell = $this->getMock('Magento_Shell', array('execute'));
     $this->_object = $this->getMock('Magento_Application', array('_bootstrap', '_cleanupMage', '_reindex', '_updateFilesystemPermissions'), array($this->_config, $this->_shell));
     $this->_object->expects($this->any())->method('_reindex')->will($this->returnValue($this->_object));
     $this->_object->applied = array();
     // For fixture testing
 }
Example #2
0
 public function testInstall()
 {
     $this->_shell->expects($this->at(1))->method('execute')->with('php -f %s -- --option1 %s --option2 %s --url %s --secure_base_url %s --admin_frontname %s --admin_username %s --admin_password %s', array($this->_installerScript, 'value 1', 'value 2', 'http://127.0.0.1/', 'http://127.0.0.1/', 'backend', 'admin', 'password1'));
     $this->_object->expects($this->once())->method('_reindex');
     $this->_object->expects($this->once())->method('_updateFilesystemPermissions');
     $this->_object->install();
 }