Code Duplication    Length = 11-12 lines in 2 locations

src/Tests/RouterTest.php 2 locations

@@ 246-256 (lines=11) @@
243
        ), $this->router->match('/bar/test/do.json', 'GET'));
244
    }
245
    
246
    public function testMatchWithWildcard()
247
    {
248
        $this->router->map('GET', '/a', 'foo_action', 'foo_route');
249
        $this->router->map('GET', '*', 'bar_action', 'bar_route');
250
        
251
        $this->assertEquals(array(
252
            'target' => 'bar_action',
253
            'params' => array(),
254
            'name' => 'bar_route'
255
        ), $this->router->match('/everything', 'GET'));
256
    }
257
    
258
    public function testMatchWithCustomRegexp()
259
    {
@@ 258-269 (lines=12) @@
255
        ), $this->router->match('/everything', 'GET'));
256
    }
257
    
258
    public function testMatchWithCustomRegexp()
259
    {
260
        $this->router->map('GET', '@^/[a-z]*$', 'bar_action', 'bar_route');
261
        
262
        $this->assertEquals(array(
263
            'target' => 'bar_action',
264
            'params' => array(),
265
            'name' => 'bar_route'
266
        ), $this->router->match('/everything', 'GET'));
267
        
268
        $this->assertFalse($this->router->match('/some-other-thing', 'GET'));
269
    }
270
271
    public function testMatchWithUnicodeRegex()
272
    {