Services::
injectMock('filters', Services::
filters(null, false
));
// Make sure validation is reset between tests
Services::
injectMock('validation', Services::
validation(null, false
));
$response =
$this->app
->
setContext('web'
) ->
setRequest($request) ->
run($routes, true
);
// Reset directory if it has been set
Services::
router()->
setDirectory(null
);
return new TestResponse($response);
} /**
* Performs a GET request.
*
* @param string $path URI path relative to baseURL. May include query.
*
* @return TestResponse
*
* @throws RedirectException
* @throws Exception
*/