public function setUp()
 {
     $config = CopixConfig::Instance();
     if (method_exists($config, 'copixtpl_clearPaths')) {
         $config->copixtpl_clearPaths();
         $config->copixtpl_addPath(COPIX_PROJECT_PATH . 'themes/');
         CopixTpl::clearFilePathCache();
     }
     $config->i18n_path_enabled = true;
     CopixTpl::setTheme('testtheme');
     CopixI18N::setLang('fr');
     CopixI18N::setCountry('FR');
     $this->themeDir = COPIX_PROJECT_PATH . 'themes/testtheme/';
     $this->defaultDir = COPIX_PROJECT_PATH . 'themes/default/';
     $this->moduleDir = CopixModule::getBasePath('copixtest') . '/copixtest/' . COPIX_TEMPLATES_DIR;
 }
 /**
  * Ajoute un module comme install dans la base de donnes
  * @param string $moduleName le nom du module  ajouter
  * @return void
  */
 private static function _addModuleInDatabase($moduleName)
 {
     //insert in database if we can
     $dao = _ioDAO('copix:CopixModule');
     if (!$dao->get($moduleName)) {
         $record = _record('copix:CopixModule');
         $record->name_cpm = $moduleName;
         $record->path_cpm = CopixModule::getBasePath($moduleName);
         $record->version_cpm = CopixModule::getInformations($moduleName)->version;
         $dao->insert($record);
     }
 }