function TMGMTNodeSourceUIOverviewTestCase::setUp in Translation Management Tool 7
Overrides DrupalWebTestCase::setUp()
Overrides TMGMTBaseTestCase::setUp
File
- sources/
node/ ui/ tmgmt_node_ui.overview.test, line 17
Class
- TMGMTNodeSourceUIOverviewTestCase
- Content Overview Tests
Code
function setUp() {
parent::setUp(array(
'tmgmt_node_ui',
));
$this
->loginAsAdmin();
$this
->setEnvironment('de');
$this
->setEnvironment('fr');
$this
->setEnvironment('es');
$this
->setEnvironment('el');
$this
->createNodeType('page', 'Page', TRANSLATION_ENABLED, FALSE);
// 1 means that the node type can have a language but is not translatable.
$this
->createNodeType('untranslated', 'Untranslated', 1, FALSE);
$this
->checkPermissions(array(), TRUE);
// Allow auto-accept.
$default_translator = tmgmt_translator_load('test_translator');
$default_translator->settings = array(
'auto_accept' => TRUE,
);
$default_translator
->save();
}