Simplify version ranges (hopefully includes hhvm), refs #3049
parent
1d8b627b57
commit
8881cec174
|
@ -131,16 +131,7 @@ class JsonFileTest extends \PHPUnit_Framework_TestCase
|
||||||
public function testFormatEmptyArray()
|
public function testFormatEmptyArray()
|
||||||
{
|
{
|
||||||
$data = array('test' => array(), 'test2' => new \stdClass);
|
$data = array('test' => array(), 'test2' => new \stdClass);
|
||||||
if (
|
if (PHP_VERSION_ID < 50429 || (PHP_VERSION_ID >= 50500 && PHP_VERSION_ID < 50513)) {
|
||||||
(PHP_VERSION_ID < 50500 && PHP_VERSION_ID >= 50429)
|
|
||||||
|| (PHP_VERSION_ID < 50600 && PHP_VERSION_ID >= 50513)
|
|
||||||
|| (PHP_VERSION_ID >= 50600)
|
|
||||||
) {
|
|
||||||
$json = '{
|
|
||||||
"test": [],
|
|
||||||
"test2": {}
|
|
||||||
}';
|
|
||||||
} else {
|
|
||||||
$json = '{
|
$json = '{
|
||||||
"test": [
|
"test": [
|
||||||
|
|
||||||
|
@ -149,7 +140,11 @@ class JsonFileTest extends \PHPUnit_Framework_TestCase
|
||||||
|
|
||||||
}
|
}
|
||||||
}';
|
}';
|
||||||
|
} else {
|
||||||
|
$json = '{
|
||||||
|
"test": [],
|
||||||
|
"test2": {}
|
||||||
|
}';
|
||||||
}
|
}
|
||||||
$this->assertJsonFormat($json, $data);
|
$this->assertJsonFormat($json, $data);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue