Skip to content

Commit ef87d7a

Browse files
committed
Add missing covers annotations to new tests.
1 parent 5c42918 commit ef87d7a

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

plugins/speculation-rules/tests/test-speculation-rules-wp-core-api.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77

88
class Test_Speculation_Rules_WP_Core_API extends WP_UnitTestCase {
99

10+
/**
11+
* @covers ::plsr_filter_speculation_rules_configuration
12+
*/
1013
public function test_plsr_filter_speculation_rules_configuration_with_regular(): void {
1114
$this->assertSame(
1215
array(
@@ -22,6 +25,9 @@ public function test_plsr_filter_speculation_rules_configuration_with_regular():
2225
);
2326
}
2427

28+
/**
29+
* @covers ::plsr_filter_speculation_rules_configuration
30+
*/
2531
public function test_plsr_filter_speculation_rules_configuration_with_invalid(): void {
2632
$this->assertSame(
2733
array(
@@ -32,10 +38,16 @@ public function test_plsr_filter_speculation_rules_configuration_with_invalid():
3238
);
3339
}
3440

41+
/**
42+
* @covers ::plsr_filter_speculation_rules_configuration
43+
*/
3544
public function test_plsr_filter_speculation_rules_configuration_with_null(): void {
3645
$this->assertNull( plsr_filter_speculation_rules_configuration( null ) );
3746
}
3847

48+
/**
49+
* @covers ::plsr_filter_speculation_rules_configuration
50+
*/
3951
public function test_plsr_filter_speculation_rules_configuration_with_pretty_permalinks_filter(): void {
4052
// Providing null while pretty permalinks are disabled should be respected.
4153
$this->disable_pretty_permalinks();
@@ -52,6 +64,9 @@ public function test_plsr_filter_speculation_rules_configuration_with_pretty_per
5264
);
5365
}
5466

67+
/**
68+
* @covers ::plsr_filter_speculation_rules_exclude_paths
69+
*/
5570
public function test_plsr_filter_speculation_rules_exclude_paths_with_regular(): void {
5671
$base_rules = array( '/membership-areas/*' );
5772

@@ -71,6 +86,9 @@ static function ( $rules ) {
7186
);
7287
}
7388

89+
/**
90+
* @covers ::plsr_filter_speculation_rules_exclude_paths
91+
*/
7492
public function test_plsr_filter_speculation_rules_exclude_paths_with_invalid(): void {
7593
$this->assertSame( array( '/personalized/*' ), plsr_filter_speculation_rules_exclude_paths( '/personalized/*', 'prefetch' ) );
7694
}

0 commit comments

Comments
 (0)