public function LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions in Lingotek Translation 8.2
Same name and namespace in other branches
- 4.0.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.0.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.1.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.2.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.3.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.4.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.5.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.6.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.7.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
- 3.8.x tests/src/Functional/LingotekUserSettingsBulkTranslationTest.php \Drupal\Tests\lingotek\Functional\LingotekUserSettingsBulkTranslationTest::testUserSettingsMultipleLanguageTranslationUsingActions()
Tests that a config object can be translated using the actions on the management page.
File
- tests/
src/ Functional/ LingotekUserSettingsBulkTranslationTest.php, line 209
Class
- LingotekUserSettingsBulkTranslationTest
- Tests translating user settings using the bulk management form.
Namespace
Drupal\Tests\lingotek\FunctionalCode
public function testUserSettingsMultipleLanguageTranslationUsingActions() {
// Login as admin.
$this
->drupalLogin($this->rootUser);
// Add a language.
ConfigurableLanguage::createFromLangcode('de')
->setThirdPartySetting('lingotek', 'locale', 'de_AT')
->save();
// Go to the bulk config management page.
$this
->goToConfigBulkManagementForm();
$basepath = \Drupal::request()
->getBasePath();
// I can init the upload of content.
$this
->assertLinkByHref($basepath . '/admin/lingotek/config/upload/entity.user.admin_form/entity.user.admin_form?destination=' . $basepath . '/admin/lingotek/config/manage');
$edit = [
'table[entity.user.admin_form]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForUpload('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
// I can check current status.
$this
->assertLinkByHref($basepath . '/admin/lingotek/config/check_upload/entity.user.admin_form/entity.user.admin_form?destination=' . $basepath . '/admin/lingotek/config/manage');
$edit = [
'table[entity.user.admin_form]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForCheckUpload('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
// Request all the translations.
$this
->assertLinkByHref($basepath . '/admin/lingotek/config/request/entity.user.admin_form/entity.user.admin_form/de_AT?destination=' . $basepath . '/admin/lingotek/config/manage');
$edit = [
'table[entity.user.admin_form]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForRequestTranslations('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
// Check status of all the translations.
$this
->assertLinkByHref($basepath . '/admin/lingotek/config/check_download/entity.user.admin_form/entity.user.admin_form/es_MX?destination=' . $basepath . '/admin/lingotek/config/manage');
$edit = [
'table[entity.user.admin_form]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForCheckTranslations('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
// Download all the translations.
$this
->assertLinkByHref($basepath . '/admin/lingotek/config/download/entity.user.admin_form/entity.user.admin_form/de_AT?destination=' . $basepath . '/admin/lingotek/config/manage');
$edit = [
'table[entity.user.admin_form]' => TRUE,
$this
->getBulkOperationFormName() => $this
->getBulkOperationNameForDownloadTranslations('node'),
];
$this
->drupalPostForm(NULL, $edit, $this
->getApplyActionsButtonLabel());
}