public function testGetTargetEntity() { $assocationMapping = array('type' => 'integer', 'fieldName' => 'position', 'targetEntity' => 'someValue'); $field = new FieldDescription(); $this->assertNull($field->getTargetEntity()); $field->setAssociationMapping($assocationMapping); $this->assertEquals('someValue', $field->getTargetEntity()); }