OrnoTest\Route\DispatcherTest::testRestfulStrategyReceivesCorrectArguments PHP Method

testRestfulStrategyReceivesCorrectArguments() public method

Assert that a route using the Restful Strategy gets passed the correct arguments
    public function testRestfulStrategyReceivesCorrectArguments()
    {
        $collection = new Route\RouteCollection();
        $collection->setStrategy(Route\RouteStrategyInterface::RESTFUL_STRATEGY);
        $collection->get('/route', function (Request $request) {
            $this->assertInstanceOf('Orno\\Http\\RequestInterface', $request);
            return new \ArrayObject();
        });
        $dispatcher = $collection->getDispatcher();
        $response = $dispatcher->dispatch('GET', '/route');
        $this->assertInstanceOf('Orno\\Http\\ResponseInterface', $response);
    }