Skip to content

Commit fddd88f

Browse files
committed
Assert what the tests want, and not more
HHVM has the __pclass property last, and not first. That doesn't matter functionality wise, but it impacts the hexdump.
1 parent ee9622a commit fddd88f

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

tests/bson/bug0334.phpt

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,11 @@ class MyClass implements BSON\Persistable {
1919
}
2020
}
2121

22-
hex_dump(fromPHP(new MyClass));
22+
$bson = fromPHP(new MyClass);
23+
$php = toPHP($bson, array('root' => 'array'));
24+
25+
var_dump($php['__pclass']->getData());
2326

2427
?>
25-
===DONE===
26-
<?php exit(0); ?>
2728
--EXPECT--
28-
0 : 28 00 00 00 05 5f 5f 70 63 6c 61 73 73 00 07 00 [(....__pclass...]
29-
10 : 00 00 80 4d 79 43 6c 61 73 73 02 66 6f 6f 00 04 [...MyClass.foo..]
30-
20 : 00 00 00 62 61 72 00 00 [...bar..]
31-
===DONE===
29+
string(7) "MyClass"

0 commit comments

Comments
 (0)