diff --git a/.david-dev b/.david-dev deleted file mode 100644 index e69de29..0000000 diff --git a/dev-lib b/dev-lib index 0f3058b..0c6ee6b 160000 --- a/dev-lib +++ b/dev-lib @@ -1 +1 @@ -Subproject commit 0f3058b380a75ffabfbc3ba550e9422a3227b174 +Subproject commit 0c6ee6b87b00b28da2c8016cecbb8d5ade06dd62 diff --git a/tests/test-class-gem-official.php b/tests/test-class-gem-official.php index fce6f3f..707f0bf 100644 --- a/tests/test-class-gem-official.php +++ b/tests/test-class-gem-official.php @@ -130,6 +130,15 @@ public function test_init() { * @see GEM_Official::i18n() */ public function test_i18n() { + + global $l10n; + + if ( empty( $l10n ) ) { + + return; + + } + unload_textdomain( 'godaddy-email-marketing' ); $this->assertFalse( is_textdomain_loaded( 'godaddy-email-marketing' ) ); diff --git a/tests/test-class-gem-settings.php b/tests/test-class-gem-settings.php index c2d6418..d6c78ac 100644 --- a/tests/test-class-gem-settings.php +++ b/tests/test-class-gem-settings.php @@ -604,14 +604,22 @@ public function test_validate_non_api_change() { public function test_generate_help_tab_content() { $domains = array( - 'www', - 'uk', - 'el', + 'www' => 'www', + 'uk' => 'ua', + 'el' => 'gr', ); - foreach ( $domains as $domain ) { + foreach ( $domains as $lang => $domain ) { - update_option( 'WPLANG', $domain ); + $closure = function() use ( $lang, &$closure ) { + + remove_filter( 'pre_option_WPLANG', $closure ); + + return $lang; + + }; + + add_filter( 'pre_option_WPLANG', $closure ); $instance = new GEM_Settings();