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

Unified Diff: tools/perf/measurements/session_restore.py

Issue 317733002: [Telemetry] Make session restore benchmark not require arguments. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: New approach Created 6 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
« no previous file with comments | « tools/perf/benchmarks/session_restore.py ('k') | tools/telemetry/telemetry/core/browser_options.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/perf/measurements/session_restore.py
diff --git a/tools/perf/measurements/session_restore.py b/tools/perf/measurements/session_restore.py
index ff210b4f3b66e2d1be4cf800ffb98b351ccb0f1e..b45f6e544fa7fa0b56c51ab31f41191a5ec6f1b7 100644
--- a/tools/perf/measurements/session_restore.py
+++ b/tools/perf/measurements/session_restore.py
@@ -1,13 +1,17 @@
# Copyright 2013 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.
+
import collections
+import logging
+import sys
from measurements import startup
from metrics import cpu
from metrics import startup_metric
from telemetry.core import util
+
class SessionRestore(startup.Startup):
"""Performs a measurement of Chromium's Session restore performance.
@@ -26,6 +30,11 @@ class SessionRestore(startup.Startup):
options.AppendExtraBrowserArgs([
'--restore-last-session'
])
+ if not options.profile_dir:
dtu 2014/06/05 01:35:28 Goes into ProcessCommandLineArgs still
+ logging.critical(
+ '--profile-dir or --profile-type is required for a session restore.\n'
+ 'For more information see: http://goo.gl/ngdGD5')
+ sys.exit(1)
def TabForPage(self, page, browser):
# Detect that the session restore has completed.
« no previous file with comments | « tools/perf/benchmarks/session_restore.py ('k') | tools/telemetry/telemetry/core/browser_options.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698