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

Side by Side Diff: test/inspector/console/let-const-with-api.js

Issue 2891213002: [inspector] Refactor protocol-test.js (Closed)
Patch Set: comments addressed Created 3 years, 7 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
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 let {session, contextGroup, Protocol} = InspectorTest.start('Tests how let and c onst interact with command line api');
6
5 Protocol.Runtime.evaluate({ expression: "let a = 42;" }).then(step2); 7 Protocol.Runtime.evaluate({ expression: "let a = 42;" }).then(step2);
6 8
7 function step2(response) 9 function step2(response)
8 { 10 {
9 failIfError(response); 11 failIfError(response);
10 InspectorTest.log("first \"let a = 1;\" result: wasThrown = " + !!response.res ult.exceptionDetails); 12 InspectorTest.log("first \"let a = 1;\" result: wasThrown = " + !!response.res ult.exceptionDetails);
11 Protocol.Runtime.evaluate({ expression: "let a = 239;" }).then(step3); 13 Protocol.Runtime.evaluate({ expression: "let a = 239;" }).then(step3);
12 } 14 }
13 15
14 function step3(response) 16 function step3(response)
(...skipping 28 matching lines...) Expand all
43 InspectorTest.completeTest(); 45 InspectorTest.completeTest();
44 46
45 Protocol.Runtime.evaluate({ expression: method, includeCommandLineAPI: true }) .then(checkMethod); 47 Protocol.Runtime.evaluate({ expression: method, includeCommandLineAPI: true }) .then(checkMethod);
46 } 48 }
47 49
48 function failIfError(response) 50 function failIfError(response)
49 { 51 {
50 if (response && response.error) 52 if (response && response.error)
51 InspectorTest.log("FAIL: " + JSON.stringify(response.error)); 53 InspectorTest.log("FAIL: " + JSON.stringify(response.error));
52 } 54 }
OLDNEW
« no previous file with comments | « test/inspector/console/destroy-context-during-log-expected.txt ('k') | test/inspector/console/let-const-with-api-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698