Unreviewed, GTK css2.1 rebaseline after r101343.
[WebKit-https.git] / LayoutTests / inspector / syntax-highlight-javascript.html
1 <html>
2 <head>
3 <script src="../http/tests/inspector/inspector-test.js"></script>
4 <script src="syntax-highlight.js"></script>
5 <script>
6
7 function test()
8 {
9     function dumpSyntaxHighlightJS(str)
10     {
11         InspectorTest.dumpSyntaxHighlight(str, "text/javascript");
12     }
13
14     dumpSyntaxHighlightJS("return'foo';");
15     dumpSyntaxHighlightJS("/\\\//g");
16     dumpSyntaxHighlightJS("//ig';");
17     dumpSyntaxHighlightJS("1 / 2 + /a/.test('a');");
18     dumpSyntaxHighlightJS("\"\\\"/\".length / 2");
19     dumpSyntaxHighlightJS("var foo = 1/*/***//2");
20     dumpSyntaxHighlightJS("/*comment*//.*/.test('a')");
21     dumpSyntaxHighlightJS("'f\\\noo';");
22     dumpSyntaxHighlightJS("'\\f\\b\\t';");
23     dumpSyntaxHighlightJS("'/\\\n/';");
24     dumpSyntaxHighlightJS("foo/**\n/\n*/foo");
25     dumpSyntaxHighlightJS("{0: true}");
26     dumpSyntaxHighlightJS("var toString;");
27
28     InspectorTest.completeTest();
29 }
30
31 </script>
32 </head>
33
34 <body onload="runTest()">
35 <p>
36 Tests that JavaScriptSourceSyntaxHighlighter detects the tokens.
37 </p>
38
39 </body>
40 </html>