Skip to content

Commit 1f910a8

Browse files
authored
Merge pull request #781 from Automattic/3.0/fix/713-nopaging-add-extra-test
2 parents 5228fdf + 6890027 commit 1f910a8

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

WordPressVIPMinimum/Tests/Performance/NoPagingUnitTest.inc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,9 @@ $args = array(
77
_query_posts( 'nopaging=true' ); // Bad.
88

99
$query_args['my_posts_per_page'] = -1; // OK.
10+
11+
// Verify handling with no trailing comma at end of array.
12+
$args = array(
13+
'nopaging' => true // Bad.
14+
);
15+
$args = [ 'nopaging' => true ]; // Bad.

WordPressVIPMinimum/Tests/Performance/NoPagingUnitTest.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,10 @@ class NoPagingUnitTest extends AbstractSniffUnitTest {
2727
*/
2828
public function getErrorList() {
2929
return [
30-
4 => 1,
31-
7 => 1,
30+
4 => 1,
31+
7 => 1,
32+
13 => 1,
33+
15 => 1,
3234
];
3335
}
3436

0 commit comments

Comments
 (0)