protected function LocaleConfigSubscriberTest::assertNoTranslation in Drupal 8
Same name and namespace in other branches
- 9 core/modules/locale/tests/src/Kernel/LocaleConfigSubscriberTest.php \Drupal\Tests\locale\Kernel\LocaleConfigSubscriberTest::assertNoTranslation()
Ensures no translation exists.
Parameters
string $config_name: The configuration name.
string $langcode: The language code.
2 calls to LocaleConfigSubscriberTest::assertNoTranslation()
- LocaleConfigSubscriberTest::setUpNoTranslation in core/
modules/ locale/ tests/ src/ Kernel/ LocaleConfigSubscriberTest.php - Sets up a configuration string without a translation.
- LocaleConfigSubscriberTest::testLocaleDeleteTranslation in core/
modules/ locale/ tests/ src/ Kernel/ LocaleConfigSubscriberTest.php - Tests deleting community translations of shipped configuration.
File
- core/
modules/ locale/ tests/ src/ Kernel/ LocaleConfigSubscriberTest.php, line 442
Class
- LocaleConfigSubscriberTest
- Tests that shipped configuration translations are updated correctly.
Namespace
Drupal\Tests\locale\KernelCode
protected function assertNoTranslation($config_name, $langcode) {
$strings = $this->stringStorage
->getTranslations([
'type' => 'configuration',
'name' => $config_name,
'language' => $langcode,
'translated' => TRUE,
]);
$this
->assertIdentical([], $strings);
}