diff options
author | Christian Schneider | 2025-10-14 16:48:37 +0200 |
---|---|---|
committer | Christian Schneider | 2025-10-14 16:50:24 +0200 |
commit | 26185bb4f1824d3cc96824d94f35cb241d344028 (patch) | |
tree | 96a28339fc90858e080853317625f8dd31b25d8c /test/it_html.t | |
parent | aef9268f09a332d56d6f0a7136eb20084a6bd32a (diff) | |
download | itools-26185bb4f1824d3cc96824d94f35cb241d344028.tar.gz itools-26185bb4f1824d3cc96824d94f35cb241d344028.tar.bz2 itools-26185bb4f1824d3cc96824d94f35cb241d344028.zip |
Simplify js() function and fix boolean attributes like 'async' => true, add tests for it
Diffstat (limited to 'test/it_html.t')
-rwxr-xr-x | test/it_html.t | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/it_html.t b/test/it_html.t index 13e2bc5..90af4b6 100755 --- a/test/it_html.t +++ b/test/it_html.t @@ -81,6 +81,8 @@ is( "leave legal utf8 intact" ); +is(js(['async' => true], 'foo'), "<script async>foo</script>\n", 'boolean attribute for js script tag'); + unset($GLOBALS['debug_utf8check']); is( div(['arg' => "value \xc2", "content"]), @@ -136,6 +138,7 @@ is( "xhtml doctype" ); +is(js('foo'), "<script type=\"text/javascript\"><!--//--><![CDATA[//><!--\nfoo\n//--><!]]></script>\n", "escape js script content with CDATA in xml mode"); # XML generation unset($GLOBALS['it_html']); |