Index: test/inspector/runtime/runtime-restore.js |
diff --git a/test/inspector/runtime/runtime-restore.js b/test/inspector/runtime/runtime-restore.js |
index 5c2fea5768d9f1b92147ca0cf22ddb8592464063..4020c19f81cb8c4d3f131e8e9722732841fab022 100644 |
--- a/test/inspector/runtime/runtime-restore.js |
+++ b/test/inspector/runtime/runtime-restore.js |
@@ -56,9 +56,9 @@ InspectorTest.runTestSuite([ |
function testSetCustomObjectFormatterEnabled(next) { |
Protocol.Runtime.onConsoleAPICalled(InspectorTest.logMessage); |
- // cleanup console message storage |
- reconnect(); |
- Protocol.Runtime.enable() |
+ Protocol.Runtime.discardConsoleEntries() |
+ .then(reconnect) |
+ .then(() => Protocol.Runtime.enable()) |
.then(() => Protocol.Runtime.setCustomObjectFormatterEnabled({ enabled: true })) |
.then(reconnect) |
.then(() => Protocol.Runtime.evaluate({ expression: 'console.log({ name: 42 })'})) |
@@ -73,5 +73,5 @@ InspectorTest.runTestSuite([ |
function reconnect() { |
InspectorTest.logMessage('will reconnect..'); |
- utils.reconnect(); |
+ InspectorTest.session.reconnect(); |
} |