static function set_up_once() {
		self::$orig['CMSBatchActionHandler_batch_actions'] = CMSBatchActionHandler::$batch_actions;
		CMSBatchActionHandler::$batch_actions = array(
			'publish' => 'CMSBatchAction_Publish',
			'delete' => 'CMSBatchAction_Delete',
			'deletefromlive' => 'CMSBatchAction_DeleteFromLive',
		);
		
		parent::set_up_once();
	}
Exemplo n.º 2
0
 static function set_up_once()
 {
     // needs to recreate the database schema with language properties
     self::kill_temp_db();
     // store old defaults
     self::$origTranslatableSettings['has_extension'] = singleton('SiteTree')->hasExtension('Translatable');
     self::$origTranslatableSettings['default_locale'] = Translatable::default_locale();
     // overwrite locale
     Translatable::set_default_locale("en_US");
     // refresh the decorated statics - different fields in $db with Translatable enabled
     if (!self::$origTranslatableSettings['has_extension']) {
         Object::add_extension('SiteTree', 'Translatable');
     }
     Object::add_extension('TranslatableTest_DataObject', 'Translatable');
     // clear singletons, they're caching old extension info which is used in DatabaseAdmin->doBuild()
     global $_SINGLETONS;
     $_SINGLETONS = array();
     // recreate database with new settings
     $dbname = self::create_temp_db();
     DB::set_alternative_database_name($dbname);
     parent::set_up_once();
 }
	static function set_up_once() {
		SiteTreeTest::set_up_once();

		parent::set_up_once();
	}