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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-scope-skip-variables-with-empty-name.html

Issue 2968523003: [DevTools] Migrate inspector-protocol/debugger tests to new harness (Closed)
Patch Set: all tests Created 3 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
OLDNEW
(Empty)
1 <html>
2 <head>
3 <script type="text/javascript" src="../../http/tests/inspector-protocol/resource s/inspector-protocol-test.js"></script>
4 <script>
5
6 function testFunction()
7 {
8 for (var a of [1]) {
9 ++a;
10 debugger;
11 }
12 }
13
14 function test()
15 {
16 InspectorTest.sendCommandOrDie("Debugger.enable", {});
17 InspectorTest.eventHandler["Debugger.paused"] = dumpScopeOnPause;
18 InspectorTest.sendCommandOrDie("Runtime.evaluate", { "expression": "testFunc tion()" });
19
20 var waitScopeObjects = 0;
21 function dumpScopeOnPause(message)
22 {
23 var scopeChain = message.params.callFrames[0].scopeChain;
24 var localScopeObjectIds = [];
25 for (var scope of scopeChain) {
26 if (scope.type === "local")
27 localScopeObjectIds.push(scope.object.objectId);
28 }
29 waitScopeObjects = localScopeObjectIds.length;
30 if (!waitScopeObjects) {
31 InspectorTest.completeTest();
32 } else {
33 for (var objectId of localScopeObjectIds)
34 InspectorTest.sendCommandOrDie("Runtime.getProperties", { "objec tId" : objectId }, dumpProperties);
35 }
36 }
37
38 function dumpProperties(message)
39 {
40 InspectorTest.logObject(message);
41 --waitScopeObjects;
42 if (!waitScopeObjects)
43 InspectorTest.sendCommandOrDie("Debugger.resume", {}, () => Inspecto rTest.completeTest());
44 }
45 }
46 </script>
47 </head>
48 <body onLoad="runTest();">
49 </body>
50 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698