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

Unified Diff: chrome/test/chromedriver/client/chromedriver.py

Issue 2065733002: Add a method to override the network conditions of the ChromeDriver session. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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/client/chromedriver.py
diff --git a/chrome/test/chromedriver/client/chromedriver.py b/chrome/test/chromedriver/client/chromedriver.py
index 4e16f0f9d9ea9c6fad9512d77cc8fe143a1547ab..6e751bf82aeb7ebdcd1443c0400502c6267e635a 100644
--- a/chrome/test/chromedriver/client/chromedriver.py
+++ b/chrome/test/chromedriver/client/chromedriver.py
@@ -409,3 +409,14 @@ class ChromeDriver(object):
def DeleteNetworkConditions(self):
self.ExecuteCommand(Command.DELETE_NETWORK_CONDITIONS)
+
+ def SetEmulatedNetworkConditions(self, connection_type):
+
+ params = {
+ 'connection_type': connection_type
samuong 2016/06/14 17:45:59 i think the spec says this should look like: para
roisinmcl 2016/06/17 18:13:33 Done.
+ }
+
+ self.ExecuteCommand(Command.SET_EMULATED_NETWORK_CONDITIONS, params)
+
+ def testNetworkConditionsDifferentWebViews(self):
+ self.ExecuteCommand(Command.NETWORK_CONDITIONS_DIFFERENT_WEBVIEWS)

Powered by Google App Engine
This is Rietveld 408576698