public function FlattenExceptionTest::testPrevious

@dataProvider flattenDataProvider

File

drupal/core/vendor/symfony/debug/Symfony/Component/Debug/Tests/Exception/FlattenExceptionTest.php, line 123

Class

FlattenExceptionTest

Namespace

Symfony\Component\Debug\Tests\Exception

Code

public function testPrevious(\Exception $exception, $statusCode) {
  $flattened = FlattenException::create($exception);
  $flattened2 = FlattenException::create($exception);
  $flattened
    ->setPrevious($flattened2);
  $this
    ->assertSame($flattened2, $flattened
    ->getPrevious());
  $this
    ->assertSame(array(
    $flattened2,
  ), $flattened
    ->getAllPrevious());
}