public function testFieldsCanBeRemoved() { $registry = new FormFieldRegistry(); $registry->add($this->getFormFieldMock('foo')); $registry->remove('foo'); $this->assertFalse($registry->has('foo')); }
/** * Returns true if the named field exists. * * @param string $name The field name * * @return bool true if the field exists, false otherwise */ public function offsetExists($name) { return $this->fields->has($name); }