public function testSerializeFieldDefaultValue()
{
$serializer = $this->getFieldTypeSerializer();
$this->getGeneratorMock()->expects($this->once())->method('generateFieldTypeHash')->with($this->equalTo('defaultValue'), $this->equalTo(array(23, 42)));
$fieldTypeMock = $this->getFieldTypeMock();
$this->getFieldTypeServiceMock()->expects($this->once())->method('getFieldType')->with($this->equalTo('myFancyFieldType'))->will($this->returnCallback(function () use($fieldTypeMock) {
return $fieldTypeMock;
}));
$fieldTypeMock->expects($this->once())->method('toHash')->with($this->equalTo('my-field-value'))->will($this->returnValue(array(23, 42)));
$serializer->serializeFieldDefaultValue($this->getGeneratorMock(), 'myFancyFieldType', 'my-field-value');
}