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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html

Issue 1638953002: [DevTools] Migrate device-emulation tests from OverridesSupport to inspector-protocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html b/third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html
index ace8802a777caaadf8021ae60a05bd5d0a7bc8af..9d14a2bfff3a8c231bba9bdee4557c3c969d9003 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector-protocol/resources/protocol-test.html
@@ -310,6 +310,21 @@ InspectorTest.safeWrap = function(func, onexception)
return result;
}
+InspectorTest.navigate = function(url, callback)
+{
+ InspectorTest._pageLoadedCallback = InspectorTest.safeWrap(callback);
+ InspectorTest.evaluateInPage("navigateProtocolTest('" + url + "')");
+}
+
+InspectorTest.pageReloaded = function()
+{
+ InspectorTest.log("Page reloaded.");
+ var callback = InspectorTest._pageLoadedCallback;
+ delete InspectorTest._pageLoadedCallback;
+ if (callback)
+ callback();
+}
+
var lastPromiseEvalId = 0;
var pendingPromiseEvalRequests = {};

Powered by Google App Engine
This is Rietveld 408576698