merged branch Tobion/flattenexception (PR #9111)
This PR was merged into the 2.3 branch.
Discussion
----------
[HttpKernel] fix usage of deprecated FlattenException
| Q | A
| ------------- | ---
| Bug fix? | yes
| New feature? | no
| BC breaks? | no
| Deprecations? | no
| Tests pass? | yes
| Fixed tickets | #9108
| License | MIT
Commits
-------
8bad61d
[HttpKernel] fix usage of deprecated FlattenException
This commit is contained in:
commit
53b2048c4c
@ -12,7 +12,7 @@
|
|||||||
namespace Symfony\Bundle\TwigBundle\Controller;
|
namespace Symfony\Bundle\TwigBundle\Controller;
|
||||||
|
|
||||||
use Symfony\Bundle\FrameworkBundle\Templating\TemplateReference;
|
use Symfony\Bundle\FrameworkBundle\Templating\TemplateReference;
|
||||||
use Symfony\Component\HttpKernel\Exception\FlattenException;
|
use Symfony\Component\Debug\Exception\FlattenException;
|
||||||
use Symfony\Component\HttpKernel\Log\DebugLoggerInterface;
|
use Symfony\Component\HttpKernel\Log\DebugLoggerInterface;
|
||||||
use Symfony\Component\HttpFoundation\Request;
|
use Symfony\Component\HttpFoundation\Request;
|
||||||
use Symfony\Component\HttpFoundation\Response;
|
use Symfony\Component\HttpFoundation\Response;
|
||||||
|
@ -19,7 +19,7 @@ class ExceptionControllerTest extends TestCase
|
|||||||
{
|
{
|
||||||
public function testOnlyClearOwnOutputBuffers()
|
public function testOnlyClearOwnOutputBuffers()
|
||||||
{
|
{
|
||||||
$flatten = $this->getMock('Symfony\Component\HttpKernel\Exception\FlattenException');
|
$flatten = $this->getMock('Symfony\Component\Debug\Exception\FlattenException');
|
||||||
$flatten
|
$flatten
|
||||||
->expects($this->once())
|
->expects($this->once())
|
||||||
->method('getStatusCode')
|
->method('getStatusCode')
|
||||||
|
@ -11,9 +11,9 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\HttpKernel\DataCollector;
|
namespace Symfony\Component\HttpKernel\DataCollector;
|
||||||
|
|
||||||
|
use Symfony\Component\Debug\Exception\FlattenException;
|
||||||
use Symfony\Component\HttpFoundation\Request;
|
use Symfony\Component\HttpFoundation\Request;
|
||||||
use Symfony\Component\HttpFoundation\Response;
|
use Symfony\Component\HttpFoundation\Response;
|
||||||
use Symfony\Component\HttpKernel\Exception\FlattenException;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ExceptionDataCollector.
|
* ExceptionDataCollector.
|
||||||
|
@ -12,11 +12,11 @@
|
|||||||
namespace Symfony\Component\HttpKernel\EventListener;
|
namespace Symfony\Component\HttpKernel\EventListener;
|
||||||
|
|
||||||
use Psr\Log\LoggerInterface;
|
use Psr\Log\LoggerInterface;
|
||||||
|
use Symfony\Component\Debug\Exception\FlattenException;
|
||||||
use Symfony\Component\HttpKernel\Log\DebugLoggerInterface;
|
use Symfony\Component\HttpKernel\Log\DebugLoggerInterface;
|
||||||
use Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent;
|
use Symfony\Component\HttpKernel\Event\GetResponseForExceptionEvent;
|
||||||
use Symfony\Component\HttpKernel\KernelEvents;
|
use Symfony\Component\HttpKernel\KernelEvents;
|
||||||
use Symfony\Component\HttpKernel\HttpKernelInterface;
|
use Symfony\Component\HttpKernel\HttpKernelInterface;
|
||||||
use Symfony\Component\HttpKernel\Exception\FlattenException;
|
|
||||||
use Symfony\Component\HttpKernel\Exception\HttpExceptionInterface;
|
use Symfony\Component\HttpKernel\Exception\HttpExceptionInterface;
|
||||||
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
|
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
|
||||||
|
|
||||||
|
@ -11,8 +11,8 @@
|
|||||||
|
|
||||||
namespace Symfony\Component\HttpKernel\Tests\DataCollector;
|
namespace Symfony\Component\HttpKernel\Tests\DataCollector;
|
||||||
|
|
||||||
|
use Symfony\Component\Debug\Exception\FlattenException;
|
||||||
use Symfony\Component\HttpKernel\DataCollector\ExceptionDataCollector;
|
use Symfony\Component\HttpKernel\DataCollector\ExceptionDataCollector;
|
||||||
use Symfony\Component\HttpKernel\Exception\FlattenException;
|
|
||||||
use Symfony\Component\HttpFoundation\Request;
|
use Symfony\Component\HttpFoundation\Request;
|
||||||
use Symfony\Component\HttpFoundation\Response;
|
use Symfony\Component\HttpFoundation\Response;
|
||||||
|
|
||||||
@ -43,5 +43,4 @@ class ExceptionDataCollectorTest extends \PHPUnit_Framework_TestCase
|
|||||||
$this->assertSame('exception', $c->getName());
|
$this->assertSame('exception', $c->getName());
|
||||||
$this->assertSame($trace, $c->getTrace());
|
$this->assertSame($trace, $c->getTrace());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user