8000 [YAML] Added support for object-maps by polyfractal · Pull Request #10114 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[YAML] Added support for object-maps #10114

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
8000
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
More formatting
  • Loading branch information
polyfractal committed Feb 21, 2014
commit 53e699250cad6745da4b4daa524a321f28201dc0
6 changes: 3 additions & 3 deletions src/Symfony/Component/Yaml/Tests/InlineTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ public function testParseWithMapObjects()
{
foreach ($this->getTestsForMapObjectParse() as $yaml => $value) {
$actual = Inline::parse($yaml, false, false, true);
if (is_object($value) === true) {
if (true === is_object($value)) {
$this->assertInstanceOf(get_class($value), $actual);
$this->assertEquals(get_object_vars($value), get_object_vars($actual));
} elseif (is_array($value) === true) {
} elseif (true === is_array($value)) {
$this->assertEquals($value, $actual);
$this->assertMixedArraysSame($value, $actual);
} else {
Expand Down Expand Up @@ -334,7 +334,7 @@ protected function assertMixedArraysSame($a, $b)
if (is_array($value)) {
$this->assertMixedArraysSame($value, $b[$key]);
} else {
if (is_object($value) === true) {
if (true === is_object($value)) {
$this->assertEquals($value, $b[$key]);
$this->assertInstanceOf(get_class($value), $b[$key]);
$this->assertEquals(get_object_vars($value), get_object_vars($b[$key]));
Expand Down
0