From 986becfd4d0e3f516e1bef4e8a1411ffdb190ff6 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 27 Oct 2020 16:07:21 +0000 Subject: [PATCH] Tests: Rename some files and classes in `phpunit/tests/post/` per the naming conventions. https://make.wordpress.org/core/handbook/testing/automated-testing/writing-phpunit-tests/#naming-and-organization Follow-up to [47780]. See #51344. git-svn-id: https://develop.svn.wordpress.org/trunk@49327 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/post/getPageUri.php | 2 +- tests/phpunit/tests/post/getPages.php | 2 +- tests/phpunit/tests/post/getPostTypeLabels.php | 2 +- tests/phpunit/tests/post/nav-menu.php | 2 +- tests/phpunit/tests/post/pings.php | 2 +- tests/phpunit/tests/post/wpGetPostParentId.php | 2 +- tests/phpunit/tests/post/wpInsertPost.php | 2 +- tests/phpunit/tests/post/{listPages.php => wpListPages.php} | 2 +- tests/phpunit/tests/post/wpPost.php | 2 +- tests/phpunit/tests/post/wpPostType.php | 2 +- .../tests/post/{wpPublishPosts.php => wpPublishPost.php} | 2 +- tests/phpunit/tests/post/wpUniquePostSlug.php | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) rename tests/phpunit/tests/post/{listPages.php => wpListPages.php} (99%) rename tests/phpunit/tests/post/{wpPublishPosts.php => wpPublishPost.php} (98%) diff --git a/tests/phpunit/tests/post/getPageUri.php b/tests/phpunit/tests/post/getPageUri.php index 5e33944c09..d313c496ed 100644 --- a/tests/phpunit/tests/post/getPageUri.php +++ b/tests/phpunit/tests/post/getPageUri.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_Post_getPageUri extends WP_UnitTestCase { +class Tests_Post_GetPageUri extends WP_UnitTestCase { /** * @ticket 22883 diff --git a/tests/phpunit/tests/post/getPages.php b/tests/phpunit/tests/post/getPages.php index 4950b5abb7..d1e88ffbd0 100644 --- a/tests/phpunit/tests/post/getPages.php +++ b/tests/phpunit/tests/post/getPages.php @@ -4,7 +4,7 @@ * @group post */ -class Tests_Post_getPages extends WP_UnitTestCase { +class Tests_Post_GetPages extends WP_UnitTestCase { function setUp() { parent::setUp(); } diff --git a/tests/phpunit/tests/post/getPostTypeLabels.php b/tests/phpunit/tests/post/getPostTypeLabels.php index aff320e641..0d66ba1f78 100644 --- a/tests/phpunit/tests/post/getPostTypeLabels.php +++ b/tests/phpunit/tests/post/getPostTypeLabels.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_Get_Post_Type_Labels extends WP_UnitTestCase { +class Tests_Post_GetPostTypeLabels extends WP_UnitTestCase { public function test_returns_an_object() { $this->assertInternalType( 'object', diff --git a/tests/phpunit/tests/post/nav-menu.php b/tests/phpunit/tests/post/nav-menu.php index d74929966f..e242066fb2 100644 --- a/tests/phpunit/tests/post/nav-menu.php +++ b/tests/phpunit/tests/post/nav-menu.php @@ -3,7 +3,7 @@ * @group post * @group menu */ -class Test_Nav_Menus extends WP_UnitTestCase { +class Tests_Post_Nav_Menu extends WP_UnitTestCase { /** * @var int */ diff --git a/tests/phpunit/tests/post/pings.php b/tests/phpunit/tests/post/pings.php index b0aebaef62..899965409e 100644 --- a/tests/phpunit/tests/post/pings.php +++ b/tests/phpunit/tests/post/pings.php @@ -4,7 +4,7 @@ * @group post * @group ping */ -class Tests_Ping_and_Trackback_Sending extends WP_UnitTestCase { +class Tests_Post_Pings extends WP_UnitTestCase { public function test_returns_to_ping_sites_from_post_id() { $post_id = self::factory()->post->create( diff --git a/tests/phpunit/tests/post/wpGetPostParentId.php b/tests/phpunit/tests/post/wpGetPostParentId.php index fe6eacde38..7080abbd6d 100644 --- a/tests/phpunit/tests/post/wpGetPostParentId.php +++ b/tests/phpunit/tests/post/wpGetPostParentId.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_Post_WpGetPostParentId extends WP_UnitTestCase { +class Tests_Post_wpGetPostParentId extends WP_UnitTestCase { /** * Parent post ID. * diff --git a/tests/phpunit/tests/post/wpInsertPost.php b/tests/phpunit/tests/post/wpInsertPost.php index a3640bf244..7fb706d00e 100644 --- a/tests/phpunit/tests/post/wpInsertPost.php +++ b/tests/phpunit/tests/post/wpInsertPost.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_WPInsertPost extends WP_UnitTestCase { +class Tests_Post_wpInsertPost extends WP_UnitTestCase { protected static $user_ids = array( 'administrator' => null, diff --git a/tests/phpunit/tests/post/listPages.php b/tests/phpunit/tests/post/wpListPages.php similarity index 99% rename from tests/phpunit/tests/post/listPages.php rename to tests/phpunit/tests/post/wpListPages.php index ba9562261c..880c63ff9d 100644 --- a/tests/phpunit/tests/post/listPages.php +++ b/tests/phpunit/tests/post/wpListPages.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_List_Pages extends WP_UnitTestCase { +class Tests_Post_wpListPages extends WP_UnitTestCase { /** * Editor user ID. * diff --git a/tests/phpunit/tests/post/wpPost.php b/tests/phpunit/tests/post/wpPost.php index a92fece2eb..801b2dc77d 100644 --- a/tests/phpunit/tests/post/wpPost.php +++ b/tests/phpunit/tests/post/wpPost.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_Post_WpPost extends WP_UnitTestCase { +class Tests_Post_wpPost extends WP_UnitTestCase { protected static $post_id; public static function wpSetUpBeforeClass( $factory ) { diff --git a/tests/phpunit/tests/post/wpPostType.php b/tests/phpunit/tests/post/wpPostType.php index 2cbc624c74..1acb6b83ba 100644 --- a/tests/phpunit/tests/post/wpPostType.php +++ b/tests/phpunit/tests/post/wpPostType.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_WP_Post_Type extends WP_UnitTestCase { +class Tests_Post_WP_Post_Type extends WP_UnitTestCase { public function test_instances() { global $wp_post_types; diff --git a/tests/phpunit/tests/post/wpPublishPosts.php b/tests/phpunit/tests/post/wpPublishPost.php similarity index 98% rename from tests/phpunit/tests/post/wpPublishPosts.php rename to tests/phpunit/tests/post/wpPublishPost.php index 00faaa1656..a5d9cc980f 100644 --- a/tests/phpunit/tests/post/wpPublishPosts.php +++ b/tests/phpunit/tests/post/wpPublishPost.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_WPPublishPost extends WP_UnitTestCase { +class Tests_Post_wpPublishPost extends WP_UnitTestCase { /** * Auto-draft post ID. diff --git a/tests/phpunit/tests/post/wpUniquePostSlug.php b/tests/phpunit/tests/post/wpUniquePostSlug.php index 45a8cd7e7d..b19d8591ae 100644 --- a/tests/phpunit/tests/post/wpUniquePostSlug.php +++ b/tests/phpunit/tests/post/wpUniquePostSlug.php @@ -3,7 +3,7 @@ /** * @group post */ -class Tests_Post_WpUniquePostSlug extends WP_UnitTestCase { +class Tests_Post_wpUniquePostSlug extends WP_UnitTestCase { protected $post_ids = array(); /**