Drupal 8  8.0.2
LocaleConfigSubscriberForeignTest Class Reference
Inheritance diagram for LocaleConfigSubscriberForeignTest:

Public Member Functions

 testDefaultConfigLanguage ()
 
 testCreateActiveTranslation ()
 
 testLocaleCreateActiveTranslation ()
 
 testUpdateActiveTranslation ()
 
 testLocaleUpdateActiveTranslation ()
 
 testDeleteTranslation ()
 
 testDeleteActiveTranslation ()
 
 testLocaleDeleteActiveTranslation ()
 
 testEnglish ()
 
- Public Member Functions inherited from LocaleConfigSubscriberTest
 testCreateTranslation ()
 
 testLocaleCreateTranslation ()
 
 testUpdateTranslation ()
 
 testLocaleUpdateTranslation ()
 
 testDeleteTranslation ()
 
 testLocaleDeleteTranslation ()
 

Protected Member Functions

 defaultLanguageData ()
 
 setUpLanguages ()
 
 setUpLocale ()
 
 saveLanguageActive ($config_name, $key, $value, $langcode)
 
- Protected Member Functions inherited from LocaleConfigSubscriberTest
 setUp ()
 
 setUpDefaultLanguage ()
 
 setUpLanguages ()
 
 setUpLocale ()
 
 setUpNoTranslation ($config_name, $key, $source, $langcode)
 
 setUpTranslation ($config_name, $key, $source, $translation, $langcode, $is_active=FALSE)
 
 saveLanguageOverride ($config_name, $key, $value, $langcode)
 
 saveLocaleTranslationData ($config_name, $key, $source, $translation, $langcode, $is_active=FALSE)
 
 deleteLanguageOverride ($config_name, $key, $source_value, $langcode)
 
 deleteLocaleTranslationData ($config_name, $key, $source_value, $langcode)
 
 assertNoConfigOverride ($config_name, $langcode)
 
 assertConfigOverride ($config_name, $key, $value, $langcode)
 
 assertActiveConfig ($config_name, $key, $value, $langcode)
 
 assertNoTranslation ($config_name, $langcode)
 

Additional Inherited Members

- Static Public Attributes inherited from LocaleConfigSubscriberTest
static $modules = ['language', 'locale', 'system']
 
- Protected Attributes inherited from LocaleConfigSubscriberTest
 $languageManager
 
 $configFactory
 
 $stringStorage
 
 $localeConfigManager
 

Detailed Description

Tests default configuration handling with a foreign default language.

locale

Member Function Documentation

defaultLanguageData ( )
protected

{}

saveLanguageActive (   $config_name,
  $key,
  $value,
  $langcode 
)
protected

Saves a language override.

This will invoke LocaleConfigSubscriber through the event dispatcher. To make sure the configuration was persisted correctly, the configuration value is checked. Because LocaleConfigSubscriber temporarily disables the override state of the configuration factory we check that the correct value is restored afterwards.

Parameters
string$config_nameThe configuration name.
string$keyThe configuration key.
string$valueThe configuration value to save.
string$langcodeThe language code.

References LocaleConfigSubscriberTest\assertActiveConfig().

Referenced by LocaleConfigSubscriberForeignTest\testCreateActiveTranslation(), and LocaleConfigSubscriberForeignTest\testUpdateActiveTranslation().

Here is the call graph for this function:

Here is the caller graph for this function:

setUpLanguages ( )
protected

{}

References ConfigurableLanguage\createFromLangcode().

Here is the call graph for this function:

setUpLocale ( )
protected

{}

References LocaleConfigSubscriberTest\setUpTranslation().

Here is the call graph for this function:

testCreateActiveTranslation ( )

Tests creating translations of shipped configuration.

References LocaleConfigSubscriberForeignTest\saveLanguageActive().

Here is the call graph for this function:

testDefaultConfigLanguage ( )

Tests that the language of default configuration was updated.

References Drupal\configFactory().

Here is the call graph for this function:

testDeleteActiveTranslation ( )

Tests deleting translations of shipped configuration.

References Drupal\configFactory().

Here is the call graph for this function:

testDeleteTranslation ( )

Tests deleting a translation override.

References LocaleConfigSubscriberTest\deleteLanguageOverride().

Here is the call graph for this function:

testEnglish ( )

Tests that adding English creates a translation override.

References LocaleConfigSubscriberTest\assertConfigOverride(), LocaleConfigSubscriberTest\assertNoConfigOverride(), Drupal\configFactory(), ConfigurableLanguage\createFromLangcode(), LocaleConfigSubscriberTest\deleteLocaleTranslationData(), LocaleConfigSubscriberTest\saveLanguageOverride(), and LocaleConfigSubscriberTest\saveLocaleTranslationData().

Here is the call graph for this function:

testLocaleCreateActiveTranslation ( )

Tests importing community translations of shipped configuration.

References LocaleConfigSubscriberTest\saveLocaleTranslationData().

Here is the call graph for this function:

testLocaleDeleteActiveTranslation ( )

Tests deleting community translations of shipped configuration.

References Drupal\configFactory(), and LocaleConfigSubscriberTest\deleteLocaleTranslationData().

Here is the call graph for this function:

testLocaleUpdateActiveTranslation ( )

Tests updating community translations of shipped configuration.

References LocaleConfigSubscriberTest\saveLocaleTranslationData().

Here is the call graph for this function:

testUpdateActiveTranslation ( )

Tests updating translations of shipped configuration.

References LocaleConfigSubscriberForeignTest\saveLanguageActive().

Here is the call graph for this function:


The documentation for this class was generated from the following file: