From e157cfb0a38f050074fd2394718653ac9cfa0559 Mon Sep 17 00:00:00 2001 From: Daryll Doyle Date: Wed, 15 Nov 2023 18:10:07 +0000 Subject: [PATCH] fix failing tests --- 10up-Default/ruleset-test.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/10up-Default/ruleset-test.php b/10up-Default/ruleset-test.php index 6c27498..0d8852f 100644 --- a/10up-Default/ruleset-test.php +++ b/10up-Default/ruleset-test.php @@ -172,10 +172,16 @@ $expected['errors'][ 222 ] = 2; } +// We have some specific errors that are only thrown on PHP 8.2+. if ( version_compare( PHP_VERSION, '8.2.0', '<' ) ) { $expected['errors'][ 486 ] = 0; } +if ( version_compare( PHP_VERSION, '7.1', '=' ) ) { + $expected['errors'][ 483 ] = 5; + $expected['warnings'][ 1 ] = 1; +} + require __DIR__ . '/../tests/RulesetTest.php'; // Run the tests!