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

Side by Side Diff: build/android/pylib/instrumentation/test_jar.py

Issue 462613005: Test Runner changes for @IntegrationTest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Refactor Created 6 years, 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | build/android/pylib/instrumentation/test_runner.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """Helper class for instrumenation test jar.""" 5 """Helper class for instrumenation test jar."""
6 # pylint: disable=W0702 6 # pylint: disable=W0702
7 7
8 import logging 8 import logging
9 import os 9 import os
10 import pickle 10 import pickle
(...skipping 11 matching lines...) Expand all
22 22
23 import unittest_util # pylint: disable=F0401 23 import unittest_util # pylint: disable=F0401
24 24
25 # If you change the cached output of proguard, increment this number 25 # If you change the cached output of proguard, increment this number
26 PICKLE_FORMAT_VERSION = 2 26 PICKLE_FORMAT_VERSION = 2
27 27
28 28
29 class TestJar(object): 29 class TestJar(object):
30 _ANNOTATIONS = frozenset( 30 _ANNOTATIONS = frozenset(
31 ['Smoke', 'SmallTest', 'MediumTest', 'LargeTest', 'EnormousTest', 31 ['Smoke', 'SmallTest', 'MediumTest', 'LargeTest', 'EnormousTest',
32 'FlakyTest', 'DisabledTest', 'Manual', 'PerfTest', 'HostDrivenTest']) 32 'FlakyTest', 'DisabledTest', 'Manual', 'PerfTest', 'HostDrivenTest',
33 'IntegrationTest'])
33 _DEFAULT_ANNOTATION = 'SmallTest' 34 _DEFAULT_ANNOTATION = 'SmallTest'
34 _PROGUARD_CLASS_RE = re.compile(r'\s*?- Program class:\s*([\S]+)$') 35 _PROGUARD_CLASS_RE = re.compile(r'\s*?- Program class:\s*([\S]+)$')
35 _PROGUARD_SUPERCLASS_RE = re.compile(r'\s*? Superclass:\s*([\S]+)$') 36 _PROGUARD_SUPERCLASS_RE = re.compile(r'\s*? Superclass:\s*([\S]+)$')
36 _PROGUARD_METHOD_RE = re.compile(r'\s*?- Method:\s*(\S*)[(].*$') 37 _PROGUARD_METHOD_RE = re.compile(r'\s*?- Method:\s*(\S*)[(].*$')
37 _PROGUARD_ANNOTATION_RE = re.compile(r'\s*?- Annotation \[L(\S*);\]:$') 38 _PROGUARD_ANNOTATION_RE = re.compile(r'\s*?- Annotation \[L(\S*);\]:$')
38 _PROGUARD_ANNOTATION_CONST_RE = ( 39 _PROGUARD_ANNOTATION_CONST_RE = (
39 re.compile(r'\s*?- Constant element value.*$')) 40 re.compile(r'\s*?- Constant element value.*$'))
40 _PROGUARD_ANNOTATION_VALUE_RE = re.compile(r'\s*?- \S+? \[(.*)\]$') 41 _PROGUARD_ANNOTATION_VALUE_RE = re.compile(r'\s*?- \S+? \[(.*)\]$')
41 42
42 def __init__(self, jar_path): 43 def __init__(self, jar_path):
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 'ro.build.version.sdk').pGet(None)] 298 'ro.build.version.sdk').pGet(None)]
298 tests = filter( 299 tests = filter(
299 lambda t: self._IsTestValidForSdkRange(t, min(sdk_versions)), 300 lambda t: self._IsTestValidForSdkRange(t, min(sdk_versions)),
300 tests) 301 tests)
301 302
302 return tests 303 return tests
303 304
304 @staticmethod 305 @staticmethod
305 def IsHostDrivenTest(test): 306 def IsHostDrivenTest(test):
306 return 'pythonDrivenTests' in test 307 return 'pythonDrivenTests' in test
OLDNEW
« no previous file with comments | « no previous file | build/android/pylib/instrumentation/test_runner.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698