- Timestamp:
- 10/20/2020 04:03:58 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/l10n/loadTextdomainJustInTime.php
r47200 r49236 33 33 add_filter( 'template_root', array( $this, 'filter_theme_root' ) ); 34 34 wp_clean_themes_cache(); 35 unset( $GLOBALS['wp_themes'] ); 36 unset( $GLOBALS['l10n'] ); 37 unset( $GLOBALS['l10n_unloaded'] ); 38 _get_path_to_translation( null, true ); 35 unset( $GLOBALS['wp_themes'], $GLOBALS['l10n'], $GLOBALS['l10n_unloaded'] ); 36 37 /** @var WP_Textdomain_Registry $wp_textdomain_registry */ 38 global $wp_textdomain_registry; 39 40 $wp_textdomain_registry->reset(); 39 41 } 40 42 … … 45 47 remove_filter( 'template_root', array( $this, 'filter_theme_root' ) ); 46 48 wp_clean_themes_cache(); 47 unset( $GLOBALS['wp_themes'] ); 48 unset( $GLOBALS['l10n'] ); 49 unset( $GLOBALS['l10n_unloaded'] ); 50 _get_path_to_translation( null, true ); 49 unset( $GLOBALS['wp_themes'], $GLOBALS['l10n'], $GLOBALS['l10n_unloaded'] ); 50 51 /** @var WP_Textdomain_Registry $wp_textdomain_registry */ 52 global $wp_textdomain_registry; 53 54 $wp_textdomain_registry->reset(); 51 55 52 56 parent::tearDown(); … … 171 175 /** 172 176 * @ticket 37997 177 * @ticket 39210 173 178 */ 174 179 public function test_plugin_translation_after_switching_locale_twice() { … … 184 189 185 190 $this->assertSame( 'Das ist ein Dummy Plugin', $expected_de_de ); 186 $this->assertSame( ' This is a dummy plugin', $expected_es_es );191 $this->assertSame( 'Este es un plugin dummy', $expected_es_es ); 187 192 } 188 193
Note: See TracChangeset
for help on using the changeset viewer.