diff options
Diffstat (limited to 'tools/chrome_proxy/live_tests/pagesets/__init__.py')
-rw-r--r-- | tools/chrome_proxy/live_tests/pagesets/__init__.py | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/tools/chrome_proxy/live_tests/pagesets/__init__.py b/tools/chrome_proxy/live_tests/pagesets/__init__.py new file mode 100644 index 0000000..1ea4db1 --- /dev/null +++ b/tools/chrome_proxy/live_tests/pagesets/__init__.py @@ -0,0 +1,20 @@ +# 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. + +import inspect +import os +import sys + +from telemetry.core import discover +from telemetry.page import page_set + + +# Import all submodules' PageSet classes. +start_dir = os.path.dirname(os.path.abspath(__file__)) +top_level_dir = os.path.abspath(os.path.join(start_dir, os.pardir, os.pardir)) +base_class = page_set.PageSet +for cls in discover.DiscoverClasses( + start_dir, top_level_dir, base_class).values(): + setattr(sys.modules[__name__], cls.__name__, cls) + |