MCPcopy Create free account
hub / github.com/ScrapeGraphAI/Scrapegraph-ai / test_minify_html

Function test_minify_html

tests/test_cleanup_html.py:70–83  ·  view source on GitHub ↗

Test minify_html function to remove comments and unnecessary whitespace.

()

Source from the content-addressed store, hash-verified

68
69
70def test_minify_html():
71 """Test minify_html function to remove comments and unnecessary whitespace."""
72 raw_html = """
73 <html>
74 <!-- this is a comment -->
75 <body>
76 <p> Hello World! </p>
77 </body>
78 </html>
79 """
80 minified = minify_html(raw_html)
81 # There should be no comment and no unnecessary spaces between tags
82 assert "<!--" not in minified
83 assert " " not in minified
84
85
86def test_reduce_html_reduction_0():

Callers

nothing calls this directly

Calls 1

minify_htmlFunction · 0.90

Tested by

no test coverage detected