Verified Commit 18e1178d authored by Alex Pott's avatar Alex Pott
Browse files

Issue #3440044 follow-up by mondrake: Replace catch of...

Issue #3440044 follow-up by mondrake: Replace catch of PHPUnit\Framework\Error\Warning in MarkupInterfaceComparatorTest

(cherry picked from commit 66645e45)
parent fdac75b8
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -109,7 +109,7 @@ public static function dataSetProvider() {
        new FormattableMarkup('GoldFinger', []),
        ['GoldFinger'],
        FALSE,
        FALSE,
        \InvalidArgumentException::class,
      ],
      'stdClass vs TranslatableMarkup' => [
        (object) ['GoldFinger'],
+3 −0
Original line number Diff line number Diff line
@@ -30,6 +30,9 @@ public function assertEquals($expected, $actual, $delta = 0.0, $canonicalize = F
    if (is_scalar($expected) && is_scalar($actual)) {
      throw new \LogicException(__METHOD__ . '() should not be called directly. Use TestCase::assertEquals() instead');
    }
    if (is_array($expected) || is_array($actual)) {
      throw new \InvalidArgumentException('Expected and actual arguments passed to ' . __METHOD__ . '() must not be arrays');
    }
    $expected_safe = (string) $expected;
    $actual_safe = (string) $actual;
    $expected_safe_stripped = strip_tags($expected_safe);