diff --git a/core/modules/translation_entity/lib/Drupal/translation_entity/Tests/EntityTranslationUITest.php b/core/modules/translation_entity/lib/Drupal/translation_entity/Tests/EntityTranslationUITest.php index 0be556d..3cb4954 100644 --- a/core/modules/translation_entity/lib/Drupal/translation_entity/Tests/EntityTranslationUITest.php +++ b/core/modules/translation_entity/lib/Drupal/translation_entity/Tests/EntityTranslationUITest.php @@ -204,12 +204,10 @@ function testTranslationUI() { $this->drupalGet($path); if ($enabled_langcode == $langcode) { $this->assertFieldByXPath('//input[@name="translation[retranslate]"]', FALSE, 'The retranslate flag is not checked by default.'); + $this->assertFalse($this->xpath('//details[@id="edit-translation" and @open="open"]'), 'The translation tab should be collapsed by default.'); } else { - // Check the fieldset is expanded by checking it does not have the - // collapsed class. - $this->assertTrue($this->xpath('//fieldset[@name="translation[translate]" and not(contains(@class, "collapsed"))]'), 'The fieldset is correctly expanded when the translation is outdated.'); - + $this->assertTrue($this->xpath('//details[@id="edit-translation" and @open="open"]'), 'The translation tab is correctly expanded when the translation is outdated.'); $this->assertFieldByXPath('//input[@name="translation[translate]"]', TRUE, 'The translate flag is checked by default.'); $edit = array('translation[translate]' => FALSE); $this->drupalPost($path, $edit, t('Save'));