diff --git a/tests/HTMLPurifier/Strategy/RemoveForeignElementsTest.php b/tests/HTMLPurifier/Strategy/RemoveForeignElementsTest.php new file mode 100644 index 00000000..cee1f8fc --- /dev/null +++ b/tests/HTMLPurifier/Strategy/RemoveForeignElementsTest.php @@ -0,0 +1,38 @@ +bold text.'; + $expect[1] = $inputs[1]; + + // [INVALID] + $inputs[2] = 'BlingBong'; + $expect[2] = htmlspecialchars($inputs[2]); + + foreach ($inputs as $i => $input) { + $tokens = $this->lex->tokenizeHTML($input); + $result_tokens = $this->strategy->execute($tokens); + $result = $this->gen->generateFromTokens($result_tokens); + $this->assertEqual($expect[$i], $result, "Test $i: %s"); + paintIf($result, $result != $expect[$i]); + } + + } + +} + +?> \ No newline at end of file