public function ExceptionStackTest::testPrintingChildException

File

drupal/core/vendor/phpunit/phpunit/Tests/_files/ExceptionStack.php, line 6

Class

ExceptionStackTest

Code

public function testPrintingChildException() {
  try {
    $this
      ->assertEquals(array(
      1,
    ), array(
      2,
    ), 'message');
  } catch (PHPUnit_Framework_ExpectationFailedException $e) {
    $message = $e
      ->getMessage() . "\n" . $e
      ->getComparisonFailure()
      ->getDiff();
    throw new ExceptionStackTestException("Child exception\n{$message}", 101, $e);
  }
}