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

Unified Diff: chrome/test/chromedriver/chrome/web_view_impl.cc

Issue 883083002: [chromedriver] Add Network Conditions Override Manager and tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix warning Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/chromedriver/chrome/web_view_impl.h ('k') | chrome/test/chromedriver/client/chromedriver.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/chromedriver/chrome/web_view_impl.cc
diff --git a/chrome/test/chromedriver/chrome/web_view_impl.cc b/chrome/test/chromedriver/chrome/web_view_impl.cc
index d703b4e30d2a5b0d9f0dc697a7d213391c6c0c73..712a36cd2d1c8cc22c108088e673038a366e4b81 100644
--- a/chrome/test/chromedriver/chrome/web_view_impl.cc
+++ b/chrome/test/chromedriver/chrome/web_view_impl.cc
@@ -24,6 +24,7 @@
#include "chrome/test/chromedriver/chrome/js.h"
#include "chrome/test/chromedriver/chrome/mobile_emulation_override_manager.h"
#include "chrome/test/chromedriver/chrome/navigation_tracker.h"
+#include "chrome/test/chromedriver/chrome/network_conditions_override_manager.h"
#include "chrome/test/chromedriver/chrome/status.h"
#include "chrome/test/chromedriver/chrome/ui_events.h"
@@ -127,6 +128,8 @@ WebViewImpl::WebViewImpl(const std::string& id,
new MobileEmulationOverrideManager(client.get(), device_metrics)),
geolocation_override_manager_(
new GeolocationOverrideManager(client.get())),
+ network_conditions_override_manager_(
+ new NetworkConditionsOverrideManager(client.get())),
heap_snapshot_taker_(new HeapSnapshotTaker(client.get())),
debugger_(new DebuggerTracker(client.get())),
client_(client.release()) {}
@@ -410,6 +413,12 @@ Status WebViewImpl::OverrideGeolocation(const Geoposition& geoposition) {
return geolocation_override_manager_->OverrideGeolocation(geoposition);
}
+Status WebViewImpl::OverrideNetworkConditions(
+ const NetworkConditions& network_conditions) {
+ return network_conditions_override_manager_->OverrideNetworkConditions(
+ network_conditions);
+}
+
Status WebViewImpl::CaptureScreenshot(std::string* screenshot) {
base::DictionaryValue params;
scoped_ptr<base::DictionaryValue> result;
« no previous file with comments | « chrome/test/chromedriver/chrome/web_view_impl.h ('k') | chrome/test/chromedriver/client/chromedriver.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698