This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
symfony/tests/Symfony/Tests/Component/DomCrawler/Field/FormFieldTestCase.php

28 lines
667 B
PHP
Raw Normal View History

2010-04-15 13:41:42 +01:00
<?php
/*
2010-04-25 16:06:54 +01:00
* This file is part of the Symfony package.
2010-04-15 13:41:42 +01:00
*
* (c) Fabien Potencier <fabien@symfony.com>
2010-04-15 13:41:42 +01:00
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Symfony\Tests\Component\DomCrawler\Field;
2010-04-15 13:41:42 +01:00
class FormFieldTestCase extends \PHPUnit_Framework_TestCase
{
protected function createNode($tag, $value, $attributes = array())
2010-04-15 13:41:42 +01:00
{
$document = new \DOMDocument();
$node = $document->createElement($tag, $value);
2010-04-15 13:41:42 +01:00
foreach ($attributes as $name => $value) {
$node->setAttribute($name, $value);
}
return $node;
}
2010-04-15 13:41:42 +01:00
}