public function testUpdateObjectDoesNotUpdatePropertyIfPropertyPathIsEmpty() { $object = new Author(); $field = new TestField('firstName', array('property_path' => null)); $field->bind('Bernhard'); $field->updateObject($object); $this->assertEquals(null, $object->firstName); }
public function testUpdateObjectThrowsExceptionIfGetterIsNotPublic() { $field = new TestField('privateSetter'); $field->bind('foobar'); $this->setExpectedException('Symfony\\Component\\Form\\Exception\\PropertyAccessDeniedException'); $field->updateObject(new Author()); }