Skip to content

Commit ae2102a

Browse files
committed
tests: added test
1 parent e2e9721 commit ae2102a

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

tests/Routers/Route.closure.phpt

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
<?php
2+
3+
/**
4+
* Test: Nette\Application\Routers\Route with closure.
5+
*/
6+
7+
use Nette\Application\Routers\Route;
8+
use Tester\Assert;
9+
10+
11+
require __DIR__ . '/../bootstrap.php';
12+
13+
require __DIR__ . '/Route.inc';
14+
15+
16+
$closure = function() {};
17+
$route = new Route('<id>', $closure);
18+
19+
testRouteIn($route, '/12', 'Nette:Micro', [
20+
'id' => '12',
21+
'test' => 'testvalue',
22+
'callback' => $closure,
23+
], '/12?test=testvalue');

0 commit comments

Comments
 (0)