Skip to content

Commit

Permalink
RouteTest: delete specific token
Browse files Browse the repository at this point in the history
  • Loading branch information
willy68 committed May 25, 2023
1 parent e794041 commit fe6d4db
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tests/Helper/RouteTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,11 @@ protected function set_up()

public function testInvokeReturnsGeneratedRoute()
{
$this->map->route('test', '/blog/{id}/edit')
->tokens([
'id' => '([0-9]+)',
]);
$this->map->route('test', '/blog/{id}/edit');

$helper = $this->container->newRouteHelper();
$this->assertEquals('/blog/42/edit', $helper('test', ['id' => '42', 'foo' => 'bar']));

$this->assertEquals('/blog/4%202/edit', $helper('test', ['id' => '4 2', 'foo' => 'bar']));
}

public function testInvokeGenerateExceptionWithToken()
Expand Down

0 comments on commit fe6d4db

Please sign in to comment.