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

Side by Side Diff: test/inspector/runtime/await-promise.js

Issue 2713023004: [inspector] added reconnect method for tests (Closed)
Patch Set: rebased Created 3 years, 9 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 | « test/inspector/protocol-test.js ('k') | test/inspector/runtime/call-function-on-async.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // Flags: --expose_gc 4 // Flags: --expose_gc
5 5
6 print("Tests that Runtime.awaitPromise works."); 6 InspectorTest.log("Tests that Runtime.awaitPromise works.");
7 7
8 InspectorTest.addScript( 8 InspectorTest.addScript(
9 ` 9 `
10 var resolveCallback; 10 var resolveCallback;
11 var rejectCallback; 11 var rejectCallback;
12 function createPromise() 12 function createPromise()
13 { 13 {
14 return new Promise((resolve, reject) => { resolveCallback = resolve; rejectC allback = reject }); 14 return new Promise((resolve, reject) => { resolveCallback = resolve; rejectC allback = reject });
15 } 15 }
16 16
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 } 107 }
108 108
109 function gcPromise(objectId) 109 function gcPromise(objectId)
110 { 110 {
111 Protocol.Runtime.releaseObject({ objectId: objectId}) 111 Protocol.Runtime.releaseObject({ objectId: objectId})
112 .then(() => Protocol.Runtime.evaluate({ expression: "gc()" })); 112 .then(() => Protocol.Runtime.evaluate({ expression: "gc()" }));
113 } 113 }
114 } 114 }
115 ]); 115 ]);
116 } 116 }
OLDNEW
« no previous file with comments | « test/inspector/protocol-test.js ('k') | test/inspector/runtime/call-function-on-async.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698