diff options
author | Aleksander Machniak <alec@alec.pl> | 2018-09-27 17:00:54 +0300 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2018-09-27 17:05:56 +0300 |
commit | c22c177e53a33d8cb89f1aae991dd452fa4135b2 (patch) | |
tree | 1c3f072ec48f31d327ac28a8e5d283ef51c117be /tests | |
parent | d310ee5bf4a02853445d794ae4da06819b9df3e7 (diff) |
Fix bug where valid content between HTML comments could have been skipped in some cases (#6464)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Framework/Washtml.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/Framework/Washtml.php b/tests/Framework/Washtml.php index 6702a1bb2..166a4612a 100644 --- a/tests/Framework/Washtml.php +++ b/tests/Framework/Washtml.php @@ -90,6 +90,11 @@ class Framework_Washtml extends PHPUnit_Framework_TestCase $washed = $washer->wash($html); $this->assertEquals('<!-- html ignored --><!-- body ignored --><p>para1</p><p>para2</p>', $washed, "HTML comments - bracket inside"); + + $html = "<p><!-- span>1</span -->\n<span>2</span>\n<!-- >3</span --><span>4</span></p>"; + $washed = $washer->wash($html); + + $this->assertEquals("<!-- html ignored --><!-- body ignored --><p>\n<span>2</span>\n<span>4</span></p>", $washed, "HTML comments (#6464)"); } /** |