コード例 #1
0
ファイル: NativeTest.php プロジェクト: sayiho/Jumper
 /**
  * @test
  */
 public function objectSerializationShouldExpected()
 {
     $this->assertEquals('O:8:"stdClass":0:{}', $this->stringifier->toString(new stdClass()));
 }
コード例 #2
0
ファイル: VarExportEvalTest.php プロジェクト: sayiho/Jumper
 /**
  * @test
  * @expectedException \Jumper\Exception\StringifierException
  * @expectedExceptionMessage VarExportEval has a limited support. Object serialization is not possible. Consider using \Jumper\Stringifier\Native stringifier.
  */
 public function objectSerializationShouldExpected()
 {
     $this->assertEquals("stdClass::__set_state(array(\n))", $this->stringifier->toString(new stdClass()));
 }
コード例 #3
0
ファイル: JsonTest.php プロジェクト: sayiho/Jumper
 /**
  * @test
  * @expectedException \Jumper\Exception\StringifierException
  * @expectedExceptionMessage Json has a limited support. Object serialization is not possible. Consider using \Jumper\Stringifier\Native stringifier.
  */
 public function objectSerializationShouldThrowStringifierException()
 {
     $this->stringifier->toString(new stdClass());
 }