From f07504e513a8c742ee75866d138ab4c72807f73f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Teixeira?= Date: Sun, 23 Oct 2016 18:09:48 -0200 Subject: [PATCH] Tests update. --- tests/TestCase/Routing/RouteBuilderTest.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/TestCase/Routing/RouteBuilderTest.php b/tests/TestCase/Routing/RouteBuilderTest.php index 76f132239c7..946bcc364ad 100644 --- a/tests/TestCase/Routing/RouteBuilderTest.php +++ b/tests/TestCase/Routing/RouteBuilderTest.php @@ -306,7 +306,7 @@ public function testRedirect() public function testPrefix() { $routes = new RouteBuilder($this->collection, '/path', ['key' => 'value']); - $res = $routes->prefix('admin', function ($r) { + $res = $routes->prefix('admin', ['key' => 'value'], function ($r) { $this->assertInstanceOf('Cake\Routing\RouteBuilder', $r); $this->assertCount(0, $this->collection->routes()); $this->assertEquals('/path/admin', $r->path()); @@ -323,9 +323,10 @@ public function testPrefix() public function testNestedPrefix() { $routes = new RouteBuilder($this->collection, '/admin', ['prefix' => 'admin']); - $res = $routes->prefix('api', function ($r) { + $res = $routes->prefix('api', ['_namePrefix' => 'api:'], function ($r) { $this->assertEquals('/admin/api', $r->path()); $this->assertEquals(['prefix' => 'admin/api'], $r->params()); + $this->assertEquals('api:', $r->namePrefix()); }); $this->assertNull($res); }