/** * @expectedException InvalidArgumentException * @expectedExceptionMessage Element "foo" does not exist. */ public function testNonExistentField() { $collection = new FieldDescriptionCollection(); $collection->get('foo'); }
/** * {@inheritdoc} */ public function get($name) { return $this->list->get($name); }