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

Unified Diff: chrome/test/chromedriver/chrome/devtools_client.h

Issue 1669453002: [chromedriver] Apply page load timeout to slow cross-process navigations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: pure virtual Created 4 years, 8 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: chrome/test/chromedriver/chrome/devtools_client.h
diff --git a/chrome/test/chromedriver/chrome/devtools_client.h b/chrome/test/chromedriver/chrome/devtools_client.h
index 32aeb810bdd98e920a9a58f254c52d64e36fe279..9365830d53d75e0aff6a7e8b0af400c684642477 100644
--- a/chrome/test/chromedriver/chrome/devtools_client.h
+++ b/chrome/test/chromedriver/chrome/devtools_client.h
@@ -12,10 +12,10 @@
namespace base {
class DictionaryValue;
-class TimeDelta;
}
class DevToolsEventListener;
+class Timeout;
class Status;
// A DevTools client of a single DevTools debugger.
@@ -36,6 +36,11 @@ class DevToolsClient {
const std::string& method,
const base::DictionaryValue& params) = 0;
+ virtual Status SendCommandWithTimeout(
+ const std::string& method,
+ const base::DictionaryValue& params,
+ const Timeout* timeout) = 0;
+
virtual Status SendAsyncCommand(
const std::string& method,
const base::DictionaryValue& params) = 0;
@@ -45,6 +50,12 @@ class DevToolsClient {
const base::DictionaryValue& params,
std::unique_ptr<base::DictionaryValue>* result) = 0;
+ virtual Status SendCommandAndGetResultWithTimeout(
+ const std::string& method,
+ const base::DictionaryValue& params,
+ const Timeout* timeout,
+ std::unique_ptr<base::DictionaryValue>* result) = 0;
+
// Adds a listener. This must only be done when the client is disconnected.
virtual void AddListener(DevToolsEventListener* listener) = 0;
@@ -54,7 +65,7 @@ class DevToolsClient {
// If the condition is not met within |timeout|, kTimeout status
// is returned eventually. If |timeout| is 0, this function will not block.
virtual Status HandleEventsUntil(const ConditionalFunc& conditional_func,
- const base::TimeDelta& timeout) = 0;
+ const Timeout& timeout) = 0;
// Handles events that have been received but not yet handled.
virtual Status HandleReceivedEvents() = 0;
« no previous file with comments | « chrome/test/chromedriver/chrome/chrome_desktop_impl.cc ('k') | chrome/test/chromedriver/chrome/devtools_client_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698