function LocalePluralFormatTest::getPoFileWithBrokenPlural
Same name in other branches
- 9 core/modules/locale/tests/src/Functional/LocalePluralFormatTest.php \Drupal\Tests\locale\Functional\LocalePluralFormatTest::getPoFileWithBrokenPlural()
- 8.9.x core/modules/locale/tests/src/Functional/LocalePluralFormatTest.php \Drupal\Tests\locale\Functional\LocalePluralFormatTest::getPoFileWithBrokenPlural()
- 11.x core/modules/locale/tests/src/Functional/LocalePluralFormatTest.php \Drupal\Tests\locale\Functional\LocalePluralFormatTest::getPoFileWithBrokenPlural()
Returns a .po file with a broken plural formula.
1 call to LocalePluralFormatTest::getPoFileWithBrokenPlural()
- LocalePluralFormatTest::testGetPluralFormat in core/
modules/ locale/ tests/ src/ Functional/ LocalePluralFormatTest.php - Tests locale_get_plural() and \Drupal::translation()->formatPlural().
File
-
core/
modules/ locale/ tests/ src/ Functional/ LocalePluralFormatTest.php, line 470
Class
- LocalePluralFormatTest
- Tests plural handling for various languages.
Namespace
Drupal\Tests\locale\FunctionalCode
public function getPoFileWithBrokenPlural() {
return <<<EOF
msgid ""
msgstr ""
"Project-Id-Version: Drupal 8\\n"
"MIME-Version: 1.0\\n"
"Content-Type: text/plain; charset=UTF-8\\n"
"Content-Transfer-Encoding: 8bit\\n"
"Plural-Forms: broken, will not parse\\n"
msgid "Monday"
msgstr "Ponedjeljak"
EOF;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.