diff --git a/tests/phpunit/tests/option/multisite.php b/tests/phpunit/tests/option/multisite.php index 4f6d194b84..c2d4a10047 100644 --- a/tests/phpunit/tests/option/multisite.php +++ b/tests/phpunit/tests/option/multisite.php @@ -9,7 +9,7 @@ if ( is_multisite() ) : * @group ms-option * @group multisite */ - class Tests_Multisite_Option extends WP_UnitTestCase { + class Tests_Option_Multisite extends WP_UnitTestCase { public function test_from_same_site() { $key = __FUNCTION__ . '_1'; diff --git a/tests/phpunit/tests/option/option.php b/tests/phpunit/tests/option/option.php index 0ed9128421..3a16afed42 100644 --- a/tests/phpunit/tests/option/option.php +++ b/tests/phpunit/tests/option/option.php @@ -224,17 +224,6 @@ class Tests_Option_Option extends WP_UnitTestCase { delete_option( 'notoptions' ); } - public function data_option_autoloading() { - return array( - array( 'autoload_yes', 'yes', 'yes' ), - array( 'autoload_true', true, 'yes' ), - array( 'autoload_string', 'foo', 'yes' ), - array( 'autoload_int', 123456, 'yes' ), - array( 'autoload_array', array(), 'yes' ), - array( 'autoload_no', 'no', 'no' ), - array( 'autoload_false', false, 'no' ), - ); - } /** * Options should be autoloaded unless they were added with "no" or `false`. * @@ -249,4 +238,21 @@ class Tests_Option_Option extends WP_UnitTestCase { $actual = $wpdb->get_row( $wpdb->prepare( "SELECT autoload FROM $wpdb->options WHERE option_name = %s LIMIT 1", $name ) ); $this->assertSame( $expected, $actual->autoload ); } + + /** + * Data provider. + * + * @return array + */ + public function data_option_autoloading() { + return array( + array( 'autoload_yes', 'yes', 'yes' ), + array( 'autoload_true', true, 'yes' ), + array( 'autoload_string', 'foo', 'yes' ), + array( 'autoload_int', 123456, 'yes' ), + array( 'autoload_array', array(), 'yes' ), + array( 'autoload_no', 'no', 'no' ), + array( 'autoload_false', false, 'no' ), + ); + } } diff --git a/tests/phpunit/tests/option/sanitize-option.php b/tests/phpunit/tests/option/sanitizeOption.php similarity index 98% rename from tests/phpunit/tests/option/sanitize-option.php rename to tests/phpunit/tests/option/sanitizeOption.php index 80342fed8f..926b7885ca 100644 --- a/tests/phpunit/tests/option/sanitize-option.php +++ b/tests/phpunit/tests/option/sanitizeOption.php @@ -3,7 +3,7 @@ /** * @group option */ -class Tests_Sanitize_Option extends WP_UnitTestCase { +class Tests_Option_SanitizeOption extends WP_UnitTestCase { /** * Data provider to test all of the sanitize_option() case diff --git a/tests/phpunit/tests/option/themeMods.php b/tests/phpunit/tests/option/themeMods.php index 5c008e8a15..1529d79fef 100644 --- a/tests/phpunit/tests/option/themeMods.php +++ b/tests/phpunit/tests/option/themeMods.php @@ -3,7 +3,7 @@ /** * @group option */ -class Tests_Option_Theme_Mods extends WP_UnitTestCase { +class Tests_Option_ThemeMods extends WP_UnitTestCase { public function test_theme_mod_default() { $this->assertFalse( get_theme_mod( 'non_existent' ) ); diff --git a/tests/phpunit/tests/option/userSettings.php b/tests/phpunit/tests/option/userSettings.php index 46ab2a899a..38ef6bf67e 100644 --- a/tests/phpunit/tests/option/userSettings.php +++ b/tests/phpunit/tests/option/userSettings.php @@ -1,8 +1,9 @@