Index: test/inspector/cpu-profiler/console-profile-end-parameterless-crash.js |
diff --git a/test/inspector/cpu-profiler/console-profile-end-parameterless-crash.js b/test/inspector/cpu-profiler/console-profile-end-parameterless-crash.js |
index 484a310fae094849009eb905d7d965823701672f..d266bb0fdc7cdf51b531bd81ce7b0e87be6ad4e5 100644 |
--- a/test/inspector/cpu-profiler/console-profile-end-parameterless-crash.js |
+++ b/test/inspector/cpu-profiler/console-profile-end-parameterless-crash.js |
@@ -4,7 +4,7 @@ |
print("Tests that \"console.profileEnd()\" does not cause crash. (webkit:105759)"); |
-InspectorTest.evaluateInPage(` |
+InspectorTest.addScript(` |
function collectProfiles() |
{ |
console.profile(); |
@@ -19,16 +19,16 @@ InspectorTest.fail = function(message) |
InspectorTest.completeTest(); |
} |
-InspectorTest.sendCommand("Profiler.enable", {}); |
-InspectorTest.sendCommand("Runtime.evaluate", { expression: "collectProfiles()"}, didCollectProfiles); |
+Protocol.Profiler.enable(); |
+Protocol.Runtime.evaluate({ expression: "collectProfiles()"}).then(didCollectProfiles); |
var headers = []; |
-InspectorTest.eventHandler["Profiler.consoleProfileFinished"] = function(messageObject) |
+Protocol.Profiler.onConsoleProfileFinished(function(messageObject) |
{ |
headers.push({ |
title: messageObject["params"]["title"] |
}); |
-} |
+}); |
function didCollectProfiles(messageObject) |
{ |