diff --git a/core/tests/Drupal/Tests/Component/Utility/XssTest.php b/core/tests/Drupal/Tests/Component/Utility/XssTest.php index be3c575..a15aa0f 100644 --- a/core/tests/Drupal/Tests/Component/Utility/XssTest.php +++ b/core/tests/Drupal/Tests/Component/Utility/XssTest.php @@ -89,11 +89,6 @@ public function testFilterXssNormalized($value, $expected, $message) { public function providerTestFilterXssNormalized() { return array( array( - "\xc0aaa", - '', - 'HTML filter -- overlong UTF-8 sequences.', - ), - array( "Who's Online", "who's online", 'HTML filter -- html entity number', @@ -103,6 +98,11 @@ public function providerTestFilterXssNormalized() { "who's online", 'HTML filter -- encoded html entity number', ), + array( + "Who' Online", + "who' online", + 'HTML filter -- double encoded html entity number', + ), ); } @@ -130,7 +130,7 @@ public function testFilterXssNotNormalized($value, $expected, $message, array $a else { $value = Xss::filter($value, $allowed_tags); } - $this->assertNotNormalized($expected, $value, $message); + $this->assertNotNormalized($value, $expected, $message); } /** @@ -442,7 +442,7 @@ public function providerTestFilterXssNotNormalized() { * @dataProvider providerTestInvalidMultiByte */ public function testInvalidMultiByte($value, $expected, $message) { - $this->assertEquals($expected, Xss::filter($value), $message); + $this->assertEquals(Xss::filter($value), $expected, $message); } /**