diff options
author | dsoares <diana.soares@gmail.com> | 2019-03-26 18:10:43 +0300 |
---|---|---|
committer | dsoares <diana.soares@gmail.com> | 2019-03-26 18:10:43 +0300 |
commit | 00cc13a1b939e4463d6cae2a603688e909d6fc1b (patch) | |
tree | 8a8115a554721ed3cc79d9fa6ca29132b2909805 /tests | |
parent | ddef3926aac2b36a22d87b8efb558047bb584f01 (diff) |
Fix bug where HTML messages with a xml:namespace tag were not rendered.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Framework/Washtml.php | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/Framework/Washtml.php b/tests/Framework/Washtml.php index eebd80de5..1dbb87a93 100644 --- a/tests/Framework/Washtml.php +++ b/tests/Framework/Washtml.php @@ -430,4 +430,18 @@ class Framework_Washtml extends PHPUnit_Framework_TestCase $this->assertContains('for="testmy-other-id"', $washed); $this->assertContains('class="testmy-class1 testmy-class2"', $washed); } + + /** + * Test removing xml:namespace tag + */ + function test_xml_namespace() + { + $html = '<p><?xml:namespace prefix = "xsl" /></p>'; + + $washer = new rcube_washtml; + $washed = $this->cleanupResult($washer->wash($html)); + + $this->assertNotContains('<?xml:namespace"', $washed); + $this->assertSame($washed, '<p></p>'); + } } |