1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-28 12:30:42 +02:00

[ticket/16549] Fix tests

PHPBB3-16549
This commit is contained in:
rxu
2020-08-10 15:02:25 +07:00
parent fc631040fd
commit ec565de6cb
43 changed files with 334 additions and 51 deletions

View File

@@ -30,7 +30,7 @@ class phpbb_functions_validate_num_test extends phpbb_test_case
$this->helper->assert_valid_data(array(
'empty' => array(
array(),
'',
null, // '' < 0 is true since PHP 8.0, hence use null instead of '' (empty string)
array('num'),
),
'zero' => array(
@@ -54,7 +54,7 @@ class phpbb_functions_validate_num_test extends phpbb_test_case
array('num', false, 2, 3),
),
'string' => array(
array(),
version_compare(PHP_VERSION, '7.5', '<=') ? [] : ['TOO_LARGE'], // See https://wiki.php.net/rfc/string_to_number_comparison
'foobar',
array('num'),
),