Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F122475862
PhutilJSONTestCase.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Jul 18, 01:53
Size
354 B
Mime Type
text/x-php
Expires
Sun, Jul 20, 01:53 (2 d)
Engine
blob
Format
Raw Data
Handle
27393855
Attached To
rPHU libphutil
PhutilJSONTestCase.php
View Options
<?php
final
class
PhutilJSONTestCase
extends
PhutilTestCase
{
public
function
testEmptyArrayEncoding
()
{
$serializer
=
new
PhutilJSON
();
$expect
=
<<<EOJSON
{
"x": []
}
EOJSON;
$this
->
assertEqual
(
$expect
,
$serializer
->
encodeFormatted
(
array
(
'x'
=>
array
())),
'Empty arrays should serialize as [], not {}.'
);
}
}
Event Timeline
Log In to Comment