Skip to content

Commit 7ce1094

Browse files
Tests: Move @covers tags to the class-level DocBlock in some block-related tests.
See #64225. git-svn-id: https://develop.svn.wordpress.org/trunk@62264 602fd350-edb4-49c9-b593-d223f7449a82
1 parent f695caa commit 7ce1094

3 files changed

Lines changed: 5 additions & 18 deletions

File tree

tests/phpunit/tests/blocks/getHookedBlocks.php

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
*
1010
* @group blocks
1111
* @group block-hooks
12+
*
13+
* @covers ::get_hooked_blocks
1214
*/
1315
class Tests_Blocks_GetHookedBlocks extends WP_UnitTestCase {
1416

@@ -58,8 +60,6 @@ private function switch_to_block_theme_hooked_blocks() {
5860

5961
/**
6062
* @ticket 59383
61-
*
62-
* @covers ::get_hooked_blocks
6363
*/
6464
public function test_get_hooked_blocks_no_match_found() {
6565
$result = get_hooked_blocks();
@@ -69,8 +69,6 @@ public function test_get_hooked_blocks_no_match_found() {
6969

7070
/**
7171
* @ticket 59383
72-
*
73-
* @covers ::get_hooked_blocks
7472
*/
7573
public function test_get_hooked_blocks_matches_found() {
7674
register_block_type(
@@ -138,7 +136,6 @@ public function test_get_hooked_blocks_matches_found() {
138136
* @ticket 60008
139137
* @ticket 60506
140138
*
141-
* @covers ::get_hooked_blocks
142139
* @covers ::get_block_file_template
143140
*/
144141
public function test_loading_template_with_hooked_blocks() {
@@ -170,7 +167,6 @@ public function test_loading_template_with_hooked_blocks() {
170167
* @ticket 60008
171168
* @ticket 60506
172169
*
173-
* @covers ::get_hooked_blocks
174170
* @covers ::get_block_file_template
175171
*/
176172
public function test_loading_template_part_with_hooked_blocks() {
@@ -202,7 +198,6 @@ public function test_loading_template_part_with_hooked_blocks() {
202198
* @ticket 60008
203199
* @ticket 60506
204200
*
205-
* @covers ::get_hooked_blocks
206201
* @covers WP_Block_Patterns_Registry::get_registered
207202
*/
208203
public function test_loading_pattern_with_hooked_blocks() {

tests/phpunit/tests/blocks/insertHookedBlocks.php

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
*
1010
* @group blocks
1111
* @group block-hooks
12+
*
13+
* @covers ::insert_hooked_blocks
1214
*/
1315
class Tests_Blocks_InsertHookedBlocks extends WP_UnitTestCase {
1416
const ANCHOR_BLOCK_TYPE = 'tests/anchor-block';
@@ -26,8 +28,6 @@ class Tests_Blocks_InsertHookedBlocks extends WP_UnitTestCase {
2628
* @ticket 59572
2729
* @ticket 60126
2830
* @ticket 60506
29-
*
30-
* @covers ::insert_hooked_blocks
3131
*/
3232
public function test_insert_hooked_blocks_returns_correct_markup() {
3333
$anchor_block = array(
@@ -46,8 +46,6 @@ public function test_insert_hooked_blocks_returns_correct_markup() {
4646
* @ticket 59572
4747
* @ticket 60126
4848
* @ticket 60506
49-
*
50-
* @covers ::insert_hooked_blocks
5149
*/
5250
public function test_insert_hooked_blocks_if_block_is_ignored() {
5351
$anchor_block = array(
@@ -71,8 +69,6 @@ public function test_insert_hooked_blocks_if_block_is_ignored() {
7169
* @ticket 59572
7270
* @ticket 60126
7371
* @ticket 60506
74-
*
75-
* @covers ::insert_hooked_blocks
7672
*/
7773
public function test_insert_hooked_blocks_if_other_block_is_ignored() {
7874
$anchor_block = array(
@@ -96,8 +92,6 @@ public function test_insert_hooked_blocks_if_other_block_is_ignored() {
9692
* @ticket 59572
9793
* @ticket 60126
9894
* @ticket 60506
99-
*
100-
* @covers ::insert_hooked_blocks
10195
*/
10296
public function test_insert_hooked_blocks_filter_can_set_attributes() {
10397
$anchor_block = array(
@@ -139,8 +133,6 @@ public function test_insert_hooked_blocks_filter_can_set_attributes() {
139133
* @ticket 59572
140134
* @ticket 60126
141135
* @ticket 60506
142-
*
143-
* @covers ::insert_hooked_blocks
144136
*/
145137
public function test_insert_hooked_blocks_filter_can_wrap_block() {
146138
$anchor_block = array(
@@ -184,7 +176,6 @@ public function test_insert_hooked_blocks_filter_can_wrap_block() {
184176
/**
185177
* @ticket 60580
186178
*
187-
* @covers ::insert_hooked_blocks
188179
*/
189180
public function test_insert_hooked_blocks_filter_can_suppress_hooked_block() {
190181
$anchor_block = array(

tests/phpunit/tests/blocks/insertHookedBlocksAndSetIgnoredHookedBlocksMetadata.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
*
1010
* @group blocks
1111
* @group block-hooks
12+
*
1213
* @covers ::insert_hooked_blocks_and_set_ignored_hooked_blocks_metadata
1314
*/
1415
class Tests_Blocks_InsertHookedBlocksAndSetIgnoredHookedBlocksMetadata extends WP_UnitTestCase {

0 commit comments

Comments
 (0)