summaryrefslogtreecommitdiffstats
path: root/core/modules/locale/src/Tests/LocaleContentTest.php
diff options
context:
space:
mode:
Diffstat (limited to 'core/modules/locale/src/Tests/LocaleContentTest.php')
-rw-r--r--core/modules/locale/src/Tests/LocaleContentTest.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/modules/locale/src/Tests/LocaleContentTest.php b/core/modules/locale/src/Tests/LocaleContentTest.php
index 093da50..7c80148 100644
--- a/core/modules/locale/src/Tests/LocaleContentTest.php
+++ b/core/modules/locale/src/Tests/LocaleContentTest.php
@@ -182,25 +182,25 @@ class LocaleContentTest extends WebTestBase {
// Check if English node does not have lang tag.
$this->drupalGet('node/' . $nodes['en']->id());
- $pattern = '|id="node-' . $nodes['en']->id() . '"[^<>]*lang="en"|';
+ $pattern = '|class="[^"]*node[^"]*"[^<>]*lang="en"|';
$this->assertNoPattern($pattern, 'The lang tag has not been assigned to the English node.');
// Check if English node does not have dir tag.
- $pattern = '|id="node-' . $nodes['en']->id() . '"[^<>]*dir="ltr"|';
+ $pattern = '|class="[^"]*node[^"]*"[^<>]*dir="ltr"|';
$this->assertNoPattern($pattern, 'The dir tag has not been assigned to the English node.');
// Check if Arabic node has lang="ar" & dir="rtl" tags.
$this->drupalGet('node/' . $nodes['ar']->id());
- $pattern = '|id="node-' . $nodes['ar']->id() . '"[^<>]*lang="ar" dir="rtl"|';
+ $pattern = '|class="[^"]*node[^"]*"[^<>]*lang="ar" dir="rtl"|';
$this->assertPattern($pattern, 'The lang and dir tags have been assigned correctly to the Arabic node.');
// Check if Spanish node has lang="es" tag.
$this->drupalGet('node/' . $nodes['es']->id());
- $pattern = '|id="node-' . $nodes['es']->id() . '"[^<>]*lang="es"|';
+ $pattern = '|class="[^"]*node[^"]*"[^<>]*lang="es"|';
$this->assertPattern($pattern, 'The lang tag has been assigned correctly to the Spanish node.');
// Check if Spanish node does not have dir="ltr" tag.
- $pattern = '|id="node-' . $nodes['es']->id() . '"[^<>]*lang="es" dir="ltr"|';
+ $pattern = '|class="[^"]*node[^"]*"[^<>]*lang="es" dir="ltr"|';
$this->assertNoPattern($pattern, 'The dir tag has not been assigned to the Spanish node.');
}