From b484fab88a9229f7c87ea053564d0d8d3d2a565d Mon Sep 17 00:00:00 2001 From: David Flatz Date: Mon, 27 May 2024 13:27:39 +0200 Subject: Improve handling of nested tags in it_html::sanitize --- test/it_html.t | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'test') diff --git a/test/it_html.t b/test/it_html.t index 11e05dd..380a779 100755 --- a/test/it_html.t +++ b/test/it_html.t @@ -289,6 +289,18 @@ is( 'TODO it_html::sanitize handle anchors with unquoted attribute value in img' ); +is( + it_html::sanitize(''), + '', + 'Nested unordered lists' +); + +is( + it_html::sanitize('

one one

'), + '

one one

', + 'More nested tags' +); + foreach (json_decode(it::file_get_contents(dirname($argv[0]) . '/U_tests.json'), true) as $test) is(U(...$test['args']), $test['exp'], $test['name']); -- cgit v1.2.3