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

Unified Diff: chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py

Issue 2563843003: [Offline Pages] Adding batch scheduling to test harness. (Closed)
Patch Set: Created 4 years 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/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageSavePageLaterEvaluationTest.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py
diff --git a/chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py b/chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py
index f835e78070bde850540557dd28387e8dd2d5a51d..bb231a6b78c8f85ecfdebe308e47a9ba2f7e8f09 100755
--- a/chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py
+++ b/chrome/browser/android/offline_pages/evaluation/run_offline_page_evaluation_test.py
@@ -27,11 +27,14 @@ import sys
DEFAULT_USER_REQUEST = True
DEFAULT_USE_TEST_SCHEDULER = False
+# 0 means the batch would be the whole list of urls.
+DEFAULT_BATCH_SIZE = 0
DEFAULT_VERBOSE = False
CONFIG_FILENAME = 'test_config'
CONFIG_TEMPLATE = """\
IsUserRequested = {is_user_requested}
UseTestScheduler = {use_test_scheduler}
+ScheduleBatchSize = {schedule_batch_size}
"""
@@ -63,6 +66,11 @@ def main(args):
action='store_false',
help='Use GCMNetworkManager for scheduling. Default option.')
parser.add_argument(
+ '--batch-size',
+ type=int,
+ dest='schedule_batch_size',
+ help='Number of pages to be queued after previous batch completes.')
+ parser.add_argument(
'-v',
'--verbose',
dest='verbose',
@@ -113,7 +121,8 @@ def main(args):
config.write(
CONFIG_TEMPLATE.format(
is_user_requested=options.user_request,
- use_test_scheduler=options.use_test_scheduler))
+ use_test_scheduler=options.use_test_scheduler,
+ schedule_batch_size=options.schedule_batch_size))
print 'Uploading config file and input file onto the device.'
subprocess.call(
« no previous file with comments | « chrome/android/javatests/src/org/chromium/chrome/browser/offlinepages/OfflinePageSavePageLaterEvaluationTest.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698