/**
  * @test
  */
 public function itUsesJMSSerializerToSerializeData()
 {
     $object = new \stdClass();
     $string = '{"some_key": "Some value"}';
     $this->jmsSerializer->shouldReceive('serialize')->once()->with($object, 'json')->andReturn($string);
     $serializedObject = $this->serializer->serialize($object);
     $this->assertSame($string, $serializedObject);
 }
 /**
  * @test
  */
 public function itSerializesAndDeserializes()
 {
     $originalObject = new Object(true, 1, 2.3, 'foo', ['bar', 'baz'], new \stdClass());
     $serializedObject = $this->serializer->serialize($originalObject);
     $this->assertInternalType('string', $serializedObject);
     $deserializedObject = $this->serializer->deserialize($serializedObject, 'SimpleES\\JMSSerializerBridge\\Test\\Auxiliary\\Object');
     $this->assertEquals($originalObject, $deserializedObject);
 }