Tests: Correct a number of malformed @covers
tags.
As per the documentation of the `@covers` tag, global functions being covered should be prefixed with `::`. Also, the `()` after the function name is redundant. Follow-up to [39918]. Props jrf. See #50267. git-svn-id: https://develop.svn.wordpress.org/trunk@48848 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
e353e266a0
commit
a6bb0120ac
@ -11,7 +11,7 @@
|
|||||||
* Tests_Comment_IsAvatarCommentType class.
|
* Tests_Comment_IsAvatarCommentType class.
|
||||||
*
|
*
|
||||||
* @group comment
|
* @group comment
|
||||||
* @covers is_avatar_comment_type
|
* @covers ::is_avatar_comment_type
|
||||||
*
|
*
|
||||||
* @since 5.1.0
|
* @since 5.1.0
|
||||||
*/
|
*/
|
||||||
|
@ -10,7 +10,7 @@ class Tests_Functions_CleanupHeaderComment extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Test cleanup header of header comment.
|
* Test cleanup header of header comment.
|
||||||
*
|
*
|
||||||
* @covers _cleanup_header_comment
|
* @covers ::_cleanup_header_comment
|
||||||
* @dataProvider data_cleanup_header_comment
|
* @dataProvider data_cleanup_header_comment
|
||||||
*
|
*
|
||||||
* @param string $test_string
|
* @param string $test_string
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*
|
*
|
||||||
* @group functions.php
|
* @group functions.php
|
||||||
* @group post
|
* @group post
|
||||||
* @covers do_enclose
|
* @covers ::do_enclose
|
||||||
*
|
*
|
||||||
* @since 5.3.0
|
* @since 5.3.0
|
||||||
*/
|
*/
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
*
|
*
|
||||||
* @since 5.3.0
|
* @since 5.3.0
|
||||||
*
|
*
|
||||||
* @covers wp_array_slice_assoc
|
* @covers ::wp_array_slice_assoc
|
||||||
* @group functions.php
|
* @group functions.php
|
||||||
*/
|
*/
|
||||||
class Tests_Functions_wpArraySliceAssoc extends WP_UnitTestCase {
|
class Tests_Functions_wpArraySliceAssoc extends WP_UnitTestCase {
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*
|
*
|
||||||
* @group link
|
* @group link
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @covers get_the_privacy_policy_link
|
* @covers ::get_the_privacy_policy_link
|
||||||
*
|
*
|
||||||
* @since 4.9.6
|
* @since 4.9.6
|
||||||
*/
|
*/
|
||||||
|
@ -31,7 +31,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Two themes with one location each should just map, switching to a theme not previously-active.
|
* Two themes with one location each should just map, switching to a theme not previously-active.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_one_location_each() {
|
function test_one_location_each() {
|
||||||
$this->register_nav_menu_locations( array( 'primary' ) );
|
$this->register_nav_menu_locations( array( 'primary' ) );
|
||||||
@ -50,7 +50,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Only registered locations should be mapped and returned.
|
* Only registered locations should be mapped and returned.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_filter_registered_locations() {
|
function test_filter_registered_locations() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
||||||
@ -72,7 +72,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Locations with the same name should map, switching to a theme not previously-active.
|
* Locations with the same name should map, switching to a theme not previously-active.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_locations_with_same_slug() {
|
function test_locations_with_same_slug() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
||||||
@ -91,7 +91,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* If the new theme was previously active, we should honor any changes to nav menu mapping done when the other theme was active.
|
* If the new theme was previously active, we should honor any changes to nav menu mapping done when the other theme was active.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_new_theme_previously_active() {
|
function test_new_theme_previously_active() {
|
||||||
$this->register_nav_menu_locations( array( 'primary' ) );
|
$this->register_nav_menu_locations( array( 'primary' ) );
|
||||||
@ -115,7 +115,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Make educated guesses on theme locations.
|
* Make educated guesses on theme locations.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_location_guessing() {
|
function test_location_guessing() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
$this->register_nav_menu_locations( array( 'primary', 'secondary' ) );
|
||||||
@ -138,7 +138,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Make sure two locations that fall in the same group don't get the same menu assigned.
|
* Make sure two locations that fall in the same group don't get the same menu assigned.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_location_guessing_one_menu_per_group() {
|
function test_location_guessing_one_menu_per_group() {
|
||||||
$this->register_nav_menu_locations( array( 'primary' ) );
|
$this->register_nav_menu_locations( array( 'primary' ) );
|
||||||
@ -159,7 +159,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
/**
|
/**
|
||||||
* Make sure two locations that fall in the same group get menus assigned from the same group.
|
* Make sure two locations that fall in the same group get menus assigned from the same group.
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_location_guessing_one_menu_per_location() {
|
function test_location_guessing_one_menu_per_location() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 'main' ) );
|
$this->register_nav_menu_locations( array( 'primary', 'main' ) );
|
||||||
@ -184,7 +184,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
*
|
*
|
||||||
* @expectedIncorrectUsage register_nav_menus
|
* @expectedIncorrectUsage register_nav_menus
|
||||||
*
|
*
|
||||||
* @covers ::wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
function test_numerical_locations() {
|
function test_numerical_locations() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 1 ) );
|
$this->register_nav_menu_locations( array( 'primary', 1 ) );
|
||||||
@ -209,7 +209,7 @@ class Tests_Nav_Menu_Theme_Change extends WP_UnitTestCase {
|
|||||||
*
|
*
|
||||||
* @expectedIncorrectUsage register_nav_menus
|
* @expectedIncorrectUsage register_nav_menus
|
||||||
*
|
*
|
||||||
* @covers wp_map_nav_menu_locations()
|
* @covers ::wp_map_nav_menu_locations
|
||||||
*/
|
*/
|
||||||
public function test_numerical_old_locations() {
|
public function test_numerical_old_locations() {
|
||||||
$this->register_nav_menu_locations( array( 'primary', 1 ) );
|
$this->register_nav_menu_locations( array( 'primary', 1 ) );
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
* Tests_WpPrivacyCompletedRequest class.
|
* Tests_WpPrivacyCompletedRequest class.
|
||||||
*
|
*
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @covers _wp_privacy_completed_request
|
* @covers ::_wp_privacy_completed_request
|
||||||
*
|
*
|
||||||
* @since 4.9.6
|
* @since 4.9.6
|
||||||
*/
|
*/
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
* Tests_Privacy_WpPrivacySendPersonalDataExportEmail class.
|
* Tests_Privacy_WpPrivacySendPersonalDataExportEmail class.
|
||||||
*
|
*
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @covers wp_privacy_send_personal_data_export_email
|
* @covers ::wp_privacy_send_personal_data_export_email
|
||||||
*
|
*
|
||||||
* @since 4.9.6
|
* @since 4.9.6
|
||||||
*/
|
*/
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*
|
*
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @group user
|
* @group user
|
||||||
* @covers _wp_privacy_send_request_confirmation_notification()
|
* @covers ::_wp_privacy_send_request_confirmation_notification
|
||||||
*/
|
*/
|
||||||
class Tests_User_WpPrivacySendRequestConfirmationNotification extends WP_UnitTestCase {
|
class Tests_User_WpPrivacySendRequestConfirmationNotification extends WP_UnitTestCase {
|
||||||
/**
|
/**
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
*
|
*
|
||||||
* @group url
|
* @group url
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @covers get_privacy_policy_url
|
* @covers ::get_privacy_policy_url
|
||||||
*
|
*
|
||||||
* @since 4.9.6
|
* @since 4.9.6
|
||||||
*/
|
*/
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
*
|
*
|
||||||
* @group privacy
|
* @group privacy
|
||||||
* @group user
|
* @group user
|
||||||
* @covers wp_send_user_request
|
* @covers ::wp_send_user_request
|
||||||
*/
|
*/
|
||||||
class Tests_User_WpSendUserRequest extends WP_UnitTestCase {
|
class Tests_User_WpSendUserRequest extends WP_UnitTestCase {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user