Skip to content

Instantly share code, notes, and snippets.

@johnwards
Created March 1, 2011 14:58
Show Gist options
  • Save johnwards/849236 to your computer and use it in GitHub Desktop.
Save johnwards/849236 to your computer and use it in GitHub Desktop.
PHPUnit 3.5.11 by Sebastian Bergmann.
PHP Fatal error: Class Mock_FormInterface_a91a62c1 must implement interface Traversable as part of either Iterator or IteratorAggregate in Unknown on line 0
Fatal error: Class Mock_FormInterface_a91a62c1 must implement interface Traversable as part of either Iterator or IteratorAggregate in Unknown on line 0
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Component\Form;
/**
* A field group bundling multiple form fields
*
* @author Bernhard Schussek <[email protected]>
*/
interface FormInterface extends FieldInterface, \ArrayAccess, \Traversable, \Countable
{
/**
* Returns whether this field group is virtual
*
* Virtual field groups are skipped when mapping property paths of a form
* tree to an object.
*
* Example:
*
* <code>
* $group = new Form('address');
* $group->add(new TextField('street'));
* $group->add(new TextField('postal_code'));
* $form->add($group);
* </code>
*
* If $group is non-virtual, the fields "street" and "postal_code"
* are mapped to the property paths "address.street" and
* "address.postal_code". If $group is virtual though, the fields are
* mapped directly to "street" and "postal_code".
*
* @return Boolean Whether the group is virtual
*/
public function isVirtual();
}
<?php
/*
* This file is part of the Symfony package.
*
* (c) Fabien Potencier <[email protected]>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Tests\Component\Form\Renderer\Plugin;
use Symfony\Component\Form\Renderer\Plugin\FormPlugin;
use Symfony\Component\Form\Renderer\DefaultRenderer;
use Symfony\Component\Form\FormInterface;
class FormPluginTest extends \PHPUnit_Framework_TestCase
{
public function testSetUp()
{
$field = $this->getMock('Symfony\Component\Form\FormInterface');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment