1
0
Fork 0

Merge pull request #5753 from alcohol/use-rfc3339-in-arraydumper

bring arraydumper in line with json schema spec and packagist
pull/5784/head
Jordi Boggiano 2016-10-12 16:51:59 +02:00 committed by GitHub
commit d9328ed5ae
2 changed files with 3 additions and 3 deletions

View File

@ -83,7 +83,7 @@ class ArrayDumper
}
if ($package->getReleaseDate()) {
$data['time'] = $package->getReleaseDate()->format('Y-m-d H:i:s');
$data['time'] = $package->getReleaseDate()->format(DATE_RFC3339);
}
$data = $this->dumpValues($package, $keys, $data);

View File

@ -104,9 +104,9 @@ class ArrayDumperTest extends \PHPUnit_Framework_TestCase
),
array(
'time',
new \DateTime('2012-02-01'),
$datetime = new \DateTime('2012-02-01'),
'ReleaseDate',
'2012-02-01 00:00:00',
$datetime->format(DATE_RFC3339),
),
array(
'authors',