public function LocalePluralFormatTest::getPoFileWithBrokenPlural in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/locale/src/Tests/LocalePluralFormatTest.php \Drupal\locale\Tests\LocalePluralFormatTest::getPoFileWithBrokenPlural()
Returns a .po file with a broken plural formula.
1 call to LocalePluralFormatTest::getPoFileWithBrokenPlural()
- LocalePluralFormatTest::testGetPluralFormat in core/
modules/ locale/ src/ Tests/ LocalePluralFormatTest.php - Tests locale_get_plural() and \Drupal::translation()->formatPlural() functionality.
File
- core/
modules/ locale/ src/ Tests/ LocalePluralFormatTest.php, line 425 - Contains \Drupal\locale\Tests\LocalePluralFormatTest.
Class
- LocalePluralFormatTest
- Tests plural handling for various languages.
Namespace
Drupal\locale\TestsCode
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;
}