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

Unified Diff: tools/chrome_proxy/integration_tests/chrome_proxy_pagesets/reenable_after_bypass.py

Issue 792303006: Remove the net-internals dependency from chrome proxy telemetry tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added unit tests for the tests Created 5 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: tools/chrome_proxy/integration_tests/chrome_proxy_pagesets/reenable_after_bypass.py
diff --git a/tools/chrome_proxy/integration_tests/chrome_proxy_pagesets/reenable_after_bypass.py b/tools/chrome_proxy/integration_tests/chrome_proxy_pagesets/reenable_after_bypass.py
new file mode 100644
index 0000000000000000000000000000000000000000..dab41686d72324e43cdd7eaef0b05a75ea4b1af3
--- /dev/null
+++ b/tools/chrome_proxy/integration_tests/chrome_proxy_pagesets/reenable_after_bypass.py
@@ -0,0 +1,41 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+from telemetry.page import page as page_module
+from telemetry.page import page_set as page_set_module
+
+
+class ReenableAfterBypassPage(page_module.Page):
+ """A test page for the re-enable after bypass tests.
+
+ Attributes:
+ bypass_seconds_low: The minimum number of seconds that the bypass
bengr 2015/01/15 00:06:09 Why aren't these bypass_seconds_min/max?
sclittle 2015/01/15 00:44:35 Sure, changed.
+ triggered by loading this page should last.
+ bypass_seconds_high: The maximum number of seconds that the bypass
+ triggered by loading this page should last.
+ """
+
+ def __init__(self,
+ url,
+ page_set,
+ bypass_seconds_low,
+ bypass_seconds_high):
+ super(ReenableAfterBypassPage, self).__init__(url=url, page_set=page_set)
+ self.bypass_seconds_low = bypass_seconds_low
+ self.bypass_seconds_high = bypass_seconds_high
+
+
+class ReenableAfterBypassPageSet(page_set_module.PageSet):
+ """ Chrome proxy test sites """
+
+ def __init__(self):
+ super(ReenableAfterBypassPageSet, self).__init__()
+
+ # Test page for "Chrome-Proxy: block=0". Loading this page should cause all
+ # data reduction proxies to be bypassed for one to five minutes.
+ self.AddUserStory(ReenableAfterBypassPage(
+ url="http://check.googlezip.net/block",
+ page_set=self,
+ bypass_seconds_low=60,
+ bypass_seconds_high=300))

Powered by Google App Engine
This is Rietveld 408576698