public function RouteCollectionTest::testSetMethods in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/routing/Tests/RouteCollectionTest.php \Symfony\Component\Routing\Tests\RouteCollectionTest::testSetMethods()
File
- vendor/
symfony/ routing/ Tests/ RouteCollectionTest.php, line 291
Class
Namespace
Symfony\Component\Routing\TestsCode
public function testSetMethods() {
$collection = new RouteCollection();
$routea = new Route('/a', array(), array(), array(), '', array(), array(
'GET',
'POST',
));
$routeb = new Route('/b');
$collection
->add('a', $routea);
$collection
->add('b', $routeb);
$collection
->setMethods('PUT');
$this
->assertEquals(array(
'PUT',
), $routea
->getMethods());
$this
->assertEquals(array(
'PUT',
), $routeb
->getMethods());
}