Beispiel #1
0
 /**
  * Initialize configuration of active modules and locales
  *
  * @return Mage_Core_Model_App
  */
 protected function _initModules()
 {
     if (!$this->_config->loadModulesCache()) {
         $this->_config->loadModules();
         if ($this->_config->isLocalConfigLoaded() && !$this->_shouldSkipProcessModulesUpdates()) {
             Magento_Profiler::start('apply_db_schema_updates');
             Mage_Core_Model_Resource_Setup::applyAllUpdates();
             Magento_Profiler::stop('apply_db_schema_updates');
         }
         $this->_config->loadDb();
         $this->_config->loadLocales();
         $this->_config->saveCache();
     }
     return $this;
 }
Beispiel #2
0
 public function testLoadLocales()
 {
     $model = new Mage_Core_Model_Config();
     $model->init(array('locale_dir' => dirname(__FILE__) . '/_files/locale'));
     $model->loadLocales();
     $this->assertInstanceOf('Mage_Core_Model_Config_Element', $model->getNode('global/locale'));
 }