diff --git a/create_framework/unit-testing.rst b/create_framework/unit-testing.rst index 7bccdceb4bd..8fa4bd000c9 100644 --- a/create_framework/unit-testing.rst +++ b/create_framework/unit-testing.rst @@ -96,6 +96,11 @@ We are now ready to write our first test:: ->method('match') ->will($this->throwException($exception)) ; + $matcher + ->expects($this->once()) + ->method('getContext') + ->will($this->returnValue($this->getMock('Symfony\Component\Routing\RequestContext'))) + ; $resolver = $this->getMock('Symfony\Component\HttpKernel\Controller\ControllerResolverInterface'); return new Framework($matcher, $resolver);