Commit e3ffe0e3 authored by frankf@google.com's avatar frankf@google.com

Reorganize Android's test scripts into packages.

This is the first attempt at splitting the scripts into
meaningful packages and make dependencies explicit.

BUG=167331

Review URL: https://codereview.chromium.org/11649008

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175441 0039d316-1c4b-4281-b951-d872f2087c98
parent 41f1745f
# Copyright (c) 2012 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.
......@@ -13,7 +13,7 @@ import string
import subprocess
import tempfile
import cmd_helper
from pylib import cmd_helper
TOMBSTONE_DIR = '/data/tombstones/'
......
......@@ -7,16 +7,17 @@ import logging
import os
import sys
import android_commands
from android_commands import errors
from base_test_runner import BaseTestRunner
import constants
from pylib import android_commands
from pylib import constants
from pylib import perf_tests_helper
from pylib.android_commands import errors
from pylib.base_test_runner import BaseTestRunner
from pylib.test_result import BaseTestResult, TestResults
from pylib.utils import run_tests_helper
import debug_info
import perf_tests_helper
from test_package_apk import TestPackageApk
from test_package_executable import TestPackageExecutable
from test_result import BaseTestResult, TestResults
from utils import run_tests_helper
class SingleTestRunner(BaseTestRunner):
......
......@@ -7,12 +7,11 @@ import logging
import re
import os
import constants
from perf_tests_helper import PrintPerfResult
from pylib import constants
from pylib import pexpect
from test_result import BaseTestResult, TestResults
from android_commands import errors
from pylib.android_commands import errors
from pylib.perf_tests_helper import PrintPerfResult
from pylib.test_result import BaseTestResult, TestResults
class TestPackage(object):
......
......@@ -9,11 +9,13 @@ import sys
import tempfile
import time
import android_commands
import constants
from android_commands import errors
from test_package import TestPackage
from pylib import android_commands
from pylib import constants
from pylib import pexpect
from pylib.android_commands import errors
from test_package import TestPackage
class TestPackageApk(TestPackage):
"""A helper class for running APK-based native tests.
......
......@@ -9,11 +9,12 @@ import shutil
import sys
import tempfile
import cmd_helper
import constants
from test_package import TestPackage
from pylib import cmd_helper
from pylib import constants
from pylib import pexpect
from test_package import TestPackage
class TestPackageExecutable(TestPackage):
"""A helper class for running stand-alone executables."""
......
# Copyright (c) 2012 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.
......@@ -6,8 +6,8 @@
import os
import android_commands
from run_java_tests import TestRunner
from pylib import android_commands
from pylib.instrumentation.run_java_tests import TestRunner
def _GetPackageName(fname):
......
......@@ -23,10 +23,10 @@ import logging
import os
import time
import android_commands
import apk_info
from run_java_tests import TestRunner
from test_result import SingleTestResult, TestResults
from pylib import android_commands
from pylib.instrumentation import apk_info
from pylib.instrumentation.run_java_tests import TestRunner
from pylib.test_result import SingleTestResult, TestResults
# aka the parent of com.google.android
......
......@@ -9,7 +9,7 @@ import logging
import sys
import time
from test_result import TestResults
from pylib.test_result import TestResults
def CallPythonTest(test, options):
......
......@@ -8,10 +8,11 @@ import copy
import logging
import multiprocessing
from pylib import sharded_tests_queue
from pylib.instrumentation.run_java_tests import FatalTestException
from pylib.test_result import TestResults
from python_test_caller import CallPythonTest
from run_java_tests import FatalTestException
import sharded_tests_queue
from test_result import TestResults
def SetTestsContainer(tests_container):
......
......@@ -9,16 +9,17 @@ import os
import sys
import types
import android_commands
import apk_info
import constants
from pylib import android_commands
from pylib import constants
from pylib.instrumentation import apk_info
from pylib.instrumentation import run_java_tests
from pylib.instrumentation.run_java_tests import FatalTestException
from pylib.test_result import TestResults
import python_test_base
from python_test_caller import CallPythonTest
from python_test_sharder import PythonTestSharder
import run_java_tests
from run_java_tests import FatalTestException
from test_info_collection import TestInfoCollection
from test_result import TestResults
def _GetPythonFiles(root, files):
......
# Copyright (c) 2012 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.
......@@ -10,7 +10,8 @@ import os
import pickle
import re
import cmd_helper
from pylib import cmd_helper
# If you change the cached output of proguard, increment this number
PICKLE_FORMAT_VERSION = 1
......
......@@ -12,19 +12,21 @@ import shutil
import sys
import time
import android_commands
from pylib import android_commands
from pylib import cmd_helper
from pylib import constants
from pylib import sharded_tests_queue
from pylib import valgrind_tools
from pylib.android_commands import errors
from pylib.base_test_runner import BaseTestRunner
from pylib.base_test_sharder import BaseTestSharder, SetTestsContainer
from pylib.forwarder import Forwarder
from pylib.json_perf_parser import GetAverageRunInfoFromJSONString
from pylib.perf_tests_helper import PrintPerfResult
from pylib.test_result import SingleTestResult, TestResults
import apk_info
from base_test_runner import BaseTestRunner
from base_test_sharder import BaseTestSharder, SetTestsContainer
import cmd_helper
import constants
import errors
from forwarder import Forwarder
from json_perf_parser import GetAverageRunInfoFromJSONString
from perf_tests_helper import PrintPerfResult
import sharded_tests_queue
from test_result import SingleTestResult, TestResults
import valgrind_tools
_PERF_TEST_ANNOTATION = 'PerfTest'
......
......@@ -11,12 +11,12 @@ import os
import sys
import time
from pylib import apk_info
from pylib import buildbot_report
from pylib import constants
from pylib import ports
from pylib import run_java_tests
from pylib import run_python_tests
from pylib.host_driven import run_python_tests
from pylib.instrumentation import apk_info
from pylib.instrumentation import run_java_tests
from pylib.test_result import TestResults
from pylib.utils import run_tests_helper
from pylib.utils import test_options_parser
......
......@@ -11,10 +11,10 @@ import sys
import time
from pylib import android_commands
from pylib import python_test_base
from pylib import python_test_sharder
from pylib import test_options_parser
from pylib import test_result
from pylib.host_driven import python_test_base
from pylib.host_driven import python_test_sharder
class MonkeyTest(python_test_base.PythonTestBase):
......
......@@ -49,10 +49,10 @@ import emulator
from pylib import android_commands
from pylib import buildbot_report
from pylib import cmd_helper
from pylib import debug_info
from pylib import ports
from pylib.base_test_sharder import BaseTestSharder
from pylib.single_test_runner import SingleTestRunner
from pylib.gtest import debug_info
from pylib.gtest.single_test_runner import SingleTestRunner
from pylib.utils import run_tests_helper
from pylib.utils import test_options_parser
from pylib.utils import time_profile
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment