General: Skip `test_is_countable_ResourceBundle()` on PHP 5.3 and below.

`ResourceBundle` is only countable in PHP 5.4+, which can be considered an acceptable edge case for WordPress core purposes.

Props jrf, ayeshrajans.
Fixes #43583.

git-svn-id: https://develop.svn.wordpress.org/trunk@43226 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2018-05-10 20:15:18 +00:00
parent 6d4c88a057
commit 34931cf8c3
1 changed files with 5 additions and 0 deletions

View File

@ -246,6 +246,11 @@ EOT;
$this->markTestSkipped( 'The intl extension is not loaded. ResourceBundle not tested for is_countable().' );
}
if ( version_compare( PHP_VERSION, '5.4', '<' ) ) {
$this->markTestSkipped( 'ResourceBundle is only countable in PHP 5.4+' );
return;
}
$this->assertTrue( is_countable( new ResourceBundle( 'en', null ) ) );
}