summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/inspector/syntax-highlight-html.html
blob: a97f5f88ed47a8596b408e08a92bfe60f65a456a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<html>
<head>
<script src="../http/tests/inspector/inspector-test.js"></script>
<script src="syntax-highlight.js"></script>
<script>

function test()
{
    function dumpSyntaxHighlightHTML(str)
    {
        InspectorTest.dumpSyntaxHighlight(str, "text/html");
    }

    dumpSyntaxHighlightHTML("<html>");
    dumpSyntaxHighlightHTML("<table cellspacing=0>");
    dumpSyntaxHighlightHTML("<input checked value=\"foo\">");
    dumpSyntaxHighlightHTML("<table cellspacing=\"0\" cellpadding='0'>");
    dumpSyntaxHighlightHTML("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3.org/TR/html4/loose.dtd\">");
    dumpSyntaxHighlightHTML("<!--div><div foobar-->");
    dumpSyntaxHighlightHTML("<script></" + "script><!--div-->");
    dumpSyntaxHighlightHTML("<script type=\"text/javascript\">document.write('<script type=\"text/javascript\"></' + 'script>');</" + "script>");

    InspectorTest.completeTest();
}

</script>
</head>

<body onload="runTest()">
<p>
Tests that SourceHTMLTokenizer detects the tokens.
</p>

</body>
</html>