Skip to content

Commit

Permalink
Updating obviously wrong test, arrays becoming maps/hashes if the inn…
Browse files Browse the repository at this point in the history
…er object is a empty stdclass is obviously wrong
  • Loading branch information
goetas committed Apr 21, 2017
1 parent b4fcdc4 commit 39f8401
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ public function testSerializeWithNonUtf8EncodingWhenDisplayErrorsOn()

public function testSerializeArrayWithEmptyObject()
{
$this->assertEquals('{"0":{}}', $this->serialize(array(new \stdClass())));
$this->assertEquals('[{}]', $this->serialize(array(new \stdClass())));
}

public function testSerializeRootArrayWithDefinedKeys()
Expand Down Expand Up @@ -350,6 +350,8 @@ public function getTypeHintedArraysAndStdClass()

return [

[[$c1], '[{}]', SerializationContext::create()->setInitialType('array<stdClass>')],

[[$c2], '[{"foo":"bar"}]', SerializationContext::create()->setInitialType('array<stdClass>')],

[[$tag], '[{"name":"tag"}]', SerializationContext::create()->setInitialType('array<JMS\Serializer\Tests\Fixtures\Tag>')],
Expand Down

0 comments on commit 39f8401

Please sign in to comment.