Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 44616d9

Browse filesBrowse files
nanocomnicolas-grekas
authored andcommitted
[Router] regression when matching a route
1 parent 7a750d4 commit 44616d9
Copy full SHA for 44616d9

File tree

1 file changed

+12
-0
lines changed
Filter options

1 file changed

+12
-0
lines changed

‎src/Symfony/Component/Routing/Tests/Matcher/UrlMatcherTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Routing/Tests/Matcher/UrlMatcherTest.php
+12Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,18 @@ public function testMatchRegression()
245245
}
246246
}
247247

248+
public function testMultipleParams()
249+
{
250+
$coll = new RouteCollection();
251+
$coll->add('foo1', new Route('/foo/{a}/{b}'));
252+
$coll->add('foo2', new Route('/foo/{a}/test/test/{b}'));
253+
$coll->add('foo3', new Route('/foo/{a}/{b}/{c}/{d}'));
254+
255+
$route = $this->getUrlMatcher($coll)->match('/foo/test/test/test/bar')['_route'];
256+
257+
$this->assertEquals('foo2', $route);
258+
}
259+
248260
public function testDefaultRequirementForOptionalVariables()
249261
{
250262
$coll = new RouteCollection();

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.