Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions 10up-Default/ruleset-test.inc
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ class TestClass extends MyClass {
}
}

// Errors: Squiz.PHP.EmbeddedPhp.ContentAfterEnd & Generic.PHP.DisallowShortOpenTag.EchoFound
// Errors: Squiz.PHP.EmbeddedPhp.ContentAfterEnd, Squiz.PHP.EmbeddedPhp.ContentAfterOpen, Squiz.PHP.EmbeddedPhp.ContentBeforeOpen & Generic.PHP.DisallowShortOpenTag.EchoFound
?> <?= esc_html( $var );

// Warnings: (Squiz.PHP.CommentedOutCode.Found <!-- Warning. -->
Expand Down Expand Up @@ -406,7 +406,7 @@ ini_alter( 'foo', true );
// Warnings: WordPress.WP.AlternativeFunctions.curl_curl_init
curl_init();

// Warnings: WordPress.WP.AlternativeFunctions.curl_curl_close
// Warnings: WordPress.WP.AlternativeFunctions.curl_curl_close & PHPCompatibility.FunctionUse.RemovedFunctions.curl_closeDeprecated
curl_close( $ch );

// Warnings: WordPress.WP.AlternativeFunctions.curl_curl_getinfo
Expand Down Expand Up @@ -484,3 +484,10 @@ $secret = mcrypt_encrypt( MCRYPT_3DES, '12345678abcdefgh', 'test', MCRYPT_MODE_C

// Function utf8_encode() is deprecated since PHP 8.2;
utf8_encode( 'test' );

?>

<!-- Must not trigger warnings or errors -->
<?php if ( is_singular() ) : ?>
<p>Also must not trigger warnings or errors.</p>
<?php endif; ?>
8 changes: 6 additions & 2 deletions 10up-Default/ruleset-test.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
146 => 1,
152 => 1,
155 => 1,
162 => 2,
162 => 4,
168 => 3,
222 => 1,
226 => 1,
Expand Down Expand Up @@ -86,6 +86,8 @@
478 => 1,
483 => 4,
486 => 1,
491 => 0,
493 => 0,
],
'warnings' => [
15 => 1,
Expand Down Expand Up @@ -146,7 +148,7 @@
338 => 1,
404 => 1,
407 => 1,
410 => 1,
410 => 2,
413 => 1,
416 => 1,
419 => 1,
Expand All @@ -162,6 +164,8 @@
449 => 1,
475 => 1,
486 => 1,
491 => 0,
493 => 0,
],
'messages' => [],
];
Expand Down
58 changes: 29 additions & 29 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading