create("/cats/"); $this->assertSame(RouteInterface::TYPE_STATIC, $route->getType()); } public function testCreatesPrefixRoute() { $factory = new RouteFactory(); $route = $factory->create("/cats/*"); $this->assertSame(RouteInterface::TYPE_PREFIX, $route->getType()); } public function testCreatesRegexRoute() { $factory = new RouteFactory(); $route = $factory->create("~/cat/[0-9]+~"); $this->assertSame(RouteInterface::TYPE_PATTERN, $route->getType()); } public function testCreatesTemplateRoute() { $factory = new RouteFactory(); $route = $factory->create("/cat/{id}"); $this->assertSame(RouteInterface::TYPE_PATTERN, $route->getType()); } }