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

Unified Diff: tools/telemetry/telemetry/test_runner.py

Issue 19597010: [telemetry] Define benchmark page sets in relation to base directory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 5 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/telemetry/telemetry/test.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/telemetry/telemetry/test_runner.py
diff --git a/tools/telemetry/telemetry/test_runner.py b/tools/telemetry/telemetry/test_runner.py
index fe9922a7843ff2bfba6b3d726d64551a0c7f8c8d..1345eaaaf63dbdf0dfe9347d679b9cd8ae2a413d 100644
--- a/tools/telemetry/telemetry/test_runner.py
+++ b/tools/telemetry/telemetry/test_runner.py
@@ -117,18 +117,10 @@ def _GetScriptName():
return os.path.basename(sys.argv[0])
-def _GetBaseDir():
- main_module = sys.modules['__main__']
- if hasattr(main_module, '__file__'):
- return os.path.dirname(main_module.__file__)
- else:
- return os.getcwd()
-
-
def _GetTests():
# Lazy load and cache results.
if not hasattr(_GetTests, 'tests'):
- base_dir = _GetBaseDir()
+ base_dir = test.GetBaseDir()
_GetTests.tests = discover.DiscoverClasses(base_dir, base_dir, test.Test,
index_by_class_name=True)
return _GetTests.tests
« no previous file with comments | « tools/telemetry/telemetry/test.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698