diff --git a/core/includes/install.inc b/core/includes/install.inc
index 649e121..71146e2 100644
--- a/core/includes/install.inc
+++ b/core/includes/install.inc
@@ -1,8 +1,7 @@
'fr',
'translation' => 'translated',
);
- $this->drupalGet('admin/config/regional/translate/translate');
$this->drupalPost('admin/config/regional/translate/translate', $search, t('Filter'));
$this->assertText(t('No strings available.'), t('Customized string not overwritten by imported string.'));
@@ -197,7 +196,7 @@ class LocaleImportFunctionalTest extends WebTestBase {
// Ensure the translation file was automatically imported when language was
// added.
- $this->assertText(t('3 translation files imported.'), t('Language file automatically imported.'));
+ $this->assertText(t('One translation files imported.'), t('Language file automatically imported.'));
$this->assertText(t('A translation string was skipped because of disallowed or malformed HTML'), t('Language file automatically imported.'));
// Ensure strings were successfully imported.
@@ -211,22 +210,24 @@ class LocaleImportFunctionalTest extends WebTestBase {
// Ensure multiline string was imported.
$search = array(
- 'string' => 'HTTP Result Code: !status',
+ 'string' => 'Source string for multiline translation',
'langcode' => $langcode,
'translation' => 'all',
);
$this->drupalPost('admin/config/regional/translate/translate', $search, t('Filter'));
- $this->assertNoText(t('No strings available.'), t('String successfully imported.'));
+ $this->assertText('Multiline translation string to make sure that import works with it.', t('String successfully imported.'));
- // Ensure xyzzy was imported and xyzzy not.
+ // Ensure 'Allowed HTML source string' was imported but the translation for
+ // 'Another allowed HTML source string' was not because it contains invalid
+ // HTML.
$search = array(
- 'string' => 'xyzzy',
+ 'string' => 'HTML source string',
'langcode' => $langcode,
'translation' => 'all',
);
$this->drupalPost('admin/config/regional/translate/translate', $search, t('Filter'));
- $this->assertNoText(t('No strings available.'), t('String successfully imported.'));
- $this->assertNoText('xyzzy2', t('String successfully imported.'));
+ $this->assertText('Allowed HTML source string', t('String successfully imported.'));
+ $this->assertNoText('Another allowed HTML source string', t('String with disallowed translation not imported.'));
}
/**
diff --git a/core/modules/locale/tests/test.xx.po b/core/modules/locale/tests/test.xx.po
index 659a6e3..65e4dff 100644
--- a/core/modules/locale/tests/test.xx.po
+++ b/core/modules/locale/tests/test.xx.po
@@ -26,3 +26,15 @@ msgstr "samedi"
msgid "Sunday"
msgstr "dimanche"
+
+msgid "Allowed HTML source string"
+msgstr "Allowed HTML translation string"
+
+msgid "Another allowed HTML source string"
+msgstr ""
+
+msgid "Source string for multiline translation"
+msgstr ""
+"Multiline translation string to"
+"to make sure that\r\n"
+"import with it."
diff --git a/core/modules/locale/tests/test2.xx.po b/core/modules/locale/tests/test2.xx.po
deleted file mode 100755
index 1733f69..0000000
--- a/core/modules/locale/tests/test2.xx.po
+++ /dev/null
@@ -1,15 +0,0 @@
-msgid ""
-msgstr ""
-"Project-Id-Version: Drupal 7\\n"
-"MIME-Version: 1.0\\n"
-"Content-Type: text/plain; charset=UTF-8\\n"
-"Content-Transfer-Encoding: 8bit\\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\\n"
-
-msgid "xyzzy"
-msgstr "html"
-
-msgid "xyzzy2"
-msgstr ""
-
-
diff --git a/core/modules/locale/tests/test3.xx.po b/core/modules/locale/tests/test3.xx.po
deleted file mode 100755
index 3840a0a..0000000
--- a/core/modules/locale/tests/test3.xx.po
+++ /dev/null
@@ -1,16 +0,0 @@
-msgid ""
-msgstr ""
-"Project-Id-Version: Drupal 7\\n"
-"MIME-Version: 1.0\\n"
-"Content-Type: text/plain; charset=UTF-8\\n"
-"Content-Transfer-Encoding: 8bit\\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\\n"
-
-msgid "HTTP Result Code: !status"
-msgstr ""
-"a multiline test"
-"second\r\n"
-"third"
-
-
-