Commit c7dca6d1 authored by alexpott's avatar alexpott
Browse files

Issue #2135101 by Gábor Hojtsy, stefank, YesCT: Fixed Expand test coverage on...

Issue #2135101 by Gábor Hojtsy, stefank, YesCT: Fixed Expand test coverage on configuration translation tabs.
parent 15089393
...@@ -71,6 +71,7 @@ protected function setUp() { ...@@ -71,6 +71,7 @@ protected function setUp() {
'access site-wide contact form', 'access site-wide contact form',
'access contextual links', 'access contextual links',
'administer views', 'administer views',
'administer account settings',
) )
); );
// Create and login user. // Create and login user.
...@@ -251,12 +252,17 @@ public function testContactConfigEntityTranslation() { ...@@ -251,12 +252,17 @@ public function testContactConfigEntityTranslation() {
$translation_base_url = 'admin/structure/contact/manage/feedback/translate'; $translation_base_url = 'admin/structure/contact/manage/feedback/translate';
$this->assertLinkByHref($translation_base_url); $this->assertLinkByHref($translation_base_url);
// Make sure translate tab is present.
$this->drupalGet('admin/structure/contact/manage/feedback');
$this->assertLink(t('Translate @type', array('@type' => 'contact form')));
// Visit the form to confirm the changes. // Visit the form to confirm the changes.
$this->drupalGet('contact/feedback'); $this->drupalGet('contact/feedback');
$this->assertText($label); $this->assertText($label);
foreach ($this->langcodes as $langcode) { foreach ($this->langcodes as $langcode) {
$this->drupalGet($translation_base_url); $this->drupalGet($translation_base_url);
$this->assertLink(t('Translate @type', array('@type' => 'contact form')));
// 'Add' link should be present for $langcode translation. // 'Add' link should be present for $langcode translation.
$translation_page_url = "$translation_base_url/$langcode/add"; $translation_page_url = "$translation_base_url/$langcode/add";
...@@ -429,7 +435,11 @@ public function testDateFormatTranslation() { ...@@ -429,7 +435,11 @@ public function testDateFormatTranslation() {
public function testAccountSettingsConfigurationTranslation() { public function testAccountSettingsConfigurationTranslation() {
$this->drupalLogin($this->admin_user); $this->drupalLogin($this->admin_user);
$this->drupalGet('admin/config/people/accounts');
$this->assertLink(t('Translate @type', array('@type' => 'account settings')));
$this->drupalGet('admin/config/people/accounts/translate'); $this->drupalGet('admin/config/people/accounts/translate');
$this->assertLink(t('Translate @type', array('@type' => 'account settings')));
$this->assertLinkByHref('admin/config/people/accounts/translate/fr/add'); $this->assertLinkByHref('admin/config/people/accounts/translate/fr/add');
// Update account settings fields for French. // Update account settings fields for French.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment