Upgraded drupal core with security updates
[yaffs-website] / web / core / modules / locale / tests / src / Functional / LocaleConfigTranslationTest.php
similarity index 97%
rename from web/core/modules/locale/src/Tests/LocaleConfigTranslationTest.php
rename to web/core/modules/locale/tests/src/Functional/LocaleConfigTranslationTest.php
index a90dce0c54c8ff3bc3b1c995a4bf3376a62d551c..4d1b9df2cd6bd70f71c976aa76152966a47715fb 100644 (file)
@@ -1,8 +1,8 @@
 <?php
 
 <?php
 
-namespace Drupal\locale\Tests;
+namespace Drupal\Tests\locale\Functional;
 
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Drupal\Core\Language\LanguageInterface;
 
 /**
 use Drupal\Core\Language\LanguageInterface;
 
 /**
@@ -10,7 +10,7 @@ use Drupal\Core\Language\LanguageInterface;
  *
  * @group locale
  */
  *
  * @group locale
  */
-class LocaleConfigTranslationTest extends WebTestBase {
+class LocaleConfigTranslationTest extends BrowserTestBase {
 
   /**
    * The language code used.
 
   /**
    * The language code used.
@@ -76,7 +76,7 @@ class LocaleConfigTranslationTest extends WebTestBase {
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textareas = $this->xpath('//textarea');
     $textarea = current($textareas);
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textareas = $this->xpath('//textarea');
     $textarea = current($textareas);
-    $lid = (string) $textarea[0]['name'];
+    $lid = $textarea->getAttribute('name');
     $edit = [
       $lid => $message,
     ];
     $edit = [
       $lid => $message,
     ];
@@ -100,7 +100,7 @@ class LocaleConfigTranslationTest extends WebTestBase {
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textareas = $this->xpath('//textarea');
     $textarea = current($textareas);
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textareas = $this->xpath('//textarea');
     $textarea = current($textareas);
-    $lid = (string) $textarea[0]['name'];
+    $lid = $textarea->getAttribute('name');
     $edit = [
       $lid => 'D',
     ];
     $edit = [
       $lid => 'D',
     ];
@@ -143,7 +143,7 @@ class LocaleConfigTranslationTest extends WebTestBase {
     ];
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textarea = current($this->xpath('//textarea'));
     ];
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textarea = current($this->xpath('//textarea'));
-    $lid = (string) $textarea[0]['name'];
+    $lid = $textarea->getAttribute('name');
     $edit = [
       $lid => $image_style_label,
     ];
     $edit = [
       $lid => $image_style_label,
     ];
@@ -175,7 +175,7 @@ class LocaleConfigTranslationTest extends WebTestBase {
     ];
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textarea = current($this->xpath('//textarea'));
     ];
     $this->drupalPostForm('admin/config/regional/translate', $search, t('Filter'));
     $textarea = current($this->xpath('//textarea'));
-    $lid = (string) $textarea[0]['name'];
+    $lid = $textarea->getAttribute('name');
     $edit = [
       $lid => $category_label,
     ];
     $edit = [
       $lid => $category_label,
     ];