Contao\CoreBundle\Test\EventListener\ExceptionConverterListenerTest::testConvertInvalidRequestTokenException PHP Method

testConvertInvalidRequestTokenException() public method

Tests converting an InvalidRequestTokenException exception.
    public function testConvertInvalidRequestTokenException()
    {
        $event = new GetResponseForExceptionEvent($this->mockKernel(), new Request(), HttpKernelInterface::MASTER_REQUEST, new InvalidRequestTokenException());
        $listener = new ExceptionConverterListener();
        $listener->onKernelException($event);
        $exception = $event->getException();
        $this->assertInstanceOf('Contao\\CoreBundle\\Exception\\InternalServerErrorHttpException', $exception);
        $this->assertInstanceOf('Contao\\CoreBundle\\Exception\\InvalidRequestTokenException', $exception->getPrevious());
    }