Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(163)

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/sources/pretty-print-javascript-7.html

Issue 2103323006: DevTools: fix javascript pretty-printing of semicolon in some cases (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/sources/pretty-print-javascript-7-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/debugger-test.js"></script>
5 <script src="../../http/tests/inspector/sources-test.js"></script>
6 <script src="debugger/resources/obfuscated.js"></script>
7
8 <script>
9
10 function test()
11 {
12 var testJSFormatter = InspectorTest.testPrettyPrint.bind(InspectorTest, "tex t/javascript");
13
14 InspectorTest.runTestSuite([
15 function semicolonAfterFunctionExpression(next)
16 {
17 var mappingQueries = ["onClick", "function", "console", "log", "clic k!", "done"];
18 testJSFormatter("var onClick = function() { console.log('click!'); } ;console.log('done');", mappingQueries, next);
19 },
20
21 function semicolonAfterMultipleFunctionExpressions(next)
22 {
23 var mappingQueries = ["onStart", "onFinish", "a()", "b()"];
24 testJSFormatter("var onStart = function() { a(); }, onFinish = funct ion() { b(); };", mappingQueries, next);
25 },
26
27 function semicolonAfterEmptyFunctionExpressions(next)
28 {
29 var mappingQueries = ["onStart", "delay", "1000", "belay", "activeEl ement"];
30 testJSFormatter("var onStart = function() {}, delay=1000, belay=docu ment.activeElement;", mappingQueries, next);
31 },
32 ]);
33 }
34
35 </script>
36
37 </head>
38
39 <body onload="runTest()">
40 <p>Verifies JavaScript pretty-printing functionality.</p>
41 </body>
42 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/sources/pretty-print-javascript-7-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698