Phil Dubach | ec19a57 | 2009-08-21 15:20:13 -0700 | [diff] [blame] | 1 | #!/usr/bin/python |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 2 | |
| 3 | # Copyright (C) 2009 The Android Open Source Project |
| 4 | # |
| 5 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | # you may not use this file except in compliance with the License. |
| 7 | # You may obtain a copy of the License at |
| 8 | # |
| 9 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | # |
| 11 | # Unless required by applicable law or agreed to in writing, software |
| 12 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
| 16 | |
| 17 | """Module for generating CTS test descriptions and test plans.""" |
| 18 | |
| 19 | import glob |
| 20 | import os |
| 21 | import re |
Unsuk Jung | 2a692d1 | 2013-09-29 20:57:32 -0700 | [diff] [blame] | 22 | import shutil |
Kalle Raita | 30e3acc | 2015-11-25 10:46:01 -0800 | [diff] [blame] | 23 | import string |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 24 | import subprocess |
| 25 | import sys |
| 26 | import xml.dom.minidom as dom |
| 27 | from cts import tools |
Brian Muramatsu | 9157e0a | 2011-04-05 18:06:15 -0700 | [diff] [blame] | 28 | from multiprocessing import Pool |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 29 | |
| 30 | def GetSubDirectories(root): |
| 31 | """Return all directories under the given root directory.""" |
| 32 | return [x for x in os.listdir(root) if os.path.isdir(os.path.join(root, x))] |
| 33 | |
Jarkko Pöyry | 1ab85bf | 2015-04-24 14:43:42 -0700 | [diff] [blame] | 34 | def ReadFileLines(filePath): |
| 35 | """Reads a file and returns its contents as a line list.""" |
| 36 | f = open(filePath, 'r'); |
| 37 | lines = [line.strip() for line in f.readlines()] |
| 38 | f.close() |
| 39 | return lines |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 40 | |
Kalle Raita | 30e3acc | 2015-11-25 10:46:01 -0800 | [diff] [blame] | 41 | def ReadDeqpTestList(testRoot, file): |
| 42 | """Reads a file, converts test names from deqp to CTS format, and returns |
| 43 | its contents as a line list. |
| 44 | """ |
| 45 | REPO_ROOT = os.path.join(testRoot, "../../..") |
| 46 | f = open(os.path.join(REPO_ROOT, "external/deqp/android/cts", file), 'r'); |
| 47 | lines = [string.join(line.strip().rsplit('.',1),'#') for line in f.readlines()] |
| 48 | f.close() |
| 49 | return lines |
| 50 | |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 51 | def GetMakeFileVars(makefile_path): |
| 52 | """Extracts variable definitions from the given make file. |
| 53 | |
| 54 | Args: |
| 55 | makefile_path: Path to the make file. |
| 56 | |
| 57 | Returns: |
| 58 | A dictionary mapping variable names to their assigned value. |
| 59 | """ |
| 60 | result = {} |
| 61 | pattern = re.compile(r'^\s*([^:#=\s]+)\s*:=\s*(.*?[^\\])$', re.MULTILINE + re.DOTALL) |
| 62 | stream = open(makefile_path, 'r') |
| 63 | content = stream.read() |
| 64 | for match in pattern.finditer(content): |
| 65 | result[match.group(1)] = match.group(2) |
| 66 | stream.close() |
| 67 | return result |
| 68 | |
| 69 | |
| 70 | class CtsBuilder(object): |
| 71 | """Main class for generating test descriptions and test plans.""" |
| 72 | |
| 73 | def __init__(self, argv): |
| 74 | """Initialize the CtsBuilder from command line arguments.""" |
Keun young Park | d93d0d1 | 2013-01-10 14:11:35 -0800 | [diff] [blame] | 75 | if len(argv) != 6: |
| 76 | print 'Usage: %s <testRoot> <ctsOutputDir> <tempDir> <androidRootDir> <docletPath>' % argv[0] |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 77 | print '' |
| 78 | print 'testRoot: Directory under which to search for CTS tests.' |
| 79 | print 'ctsOutputDir: Directory in which the CTS repository should be created.' |
| 80 | print 'tempDir: Directory to use for storing temporary files.' |
| 81 | print 'androidRootDir: Root directory of the Android source tree.' |
| 82 | print 'docletPath: Class path where the DescriptionGenerator doclet can be found.' |
| 83 | sys.exit(1) |
| 84 | self.test_root = sys.argv[1] |
| 85 | self.out_dir = sys.argv[2] |
| 86 | self.temp_dir = sys.argv[3] |
| 87 | self.android_root = sys.argv[4] |
| 88 | self.doclet_path = sys.argv[5] |
| 89 | |
| 90 | self.test_repository = os.path.join(self.out_dir, 'repository/testcases') |
| 91 | self.plan_repository = os.path.join(self.out_dir, 'repository/plans') |
Unsuk Jung | 08d97f9 | 2013-09-29 22:40:22 -0700 | [diff] [blame] | 92 | self.definedplans_repository = os.path.join(self.android_root, 'cts/tests/plans') |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 93 | |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 94 | def GenerateTestDescriptions(self): |
| 95 | """Generate test descriptions for all packages.""" |
Brian Muramatsu | 5df641c | 2011-12-28 15:46:57 -0800 | [diff] [blame] | 96 | pool = Pool(processes=2) |
Brian Muramatsu | 9157e0a | 2011-04-05 18:06:15 -0700 | [diff] [blame] | 97 | |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 98 | # generate test descriptions for android tests |
Brian Muramatsu | bdcfc7c | 2011-12-01 14:32:02 -0800 | [diff] [blame] | 99 | results = [] |
Brian Muramatsu | 9157e0a | 2011-04-05 18:06:15 -0700 | [diff] [blame] | 100 | pool.close() |
| 101 | pool.join() |
Brian Muramatsu | bdcfc7c | 2011-12-01 14:32:02 -0800 | [diff] [blame] | 102 | return sum(map(lambda result: result.get(), results)) |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 103 | |
| 104 | def __WritePlan(self, plan, plan_name): |
| 105 | print 'Generating test plan %s' % plan_name |
| 106 | plan.Write(os.path.join(self.plan_repository, plan_name + '.xml')) |
| 107 | |
| 108 | def GenerateTestPlans(self): |
| 109 | """Generate default test plans.""" |
| 110 | # TODO: Instead of hard-coding the plans here, use a configuration file, |
| 111 | # such as test_defs.xml |
| 112 | packages = [] |
Phil Dubach | 8dcedfe | 2009-08-20 16:10:39 -0700 | [diff] [blame] | 113 | descriptions = sorted(glob.glob(os.path.join(self.test_repository, '*.xml'))) |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 114 | for description in descriptions: |
| 115 | doc = tools.XmlFile(description) |
| 116 | packages.append(doc.GetAttr('TestPackage', 'appPackageName')) |
Keun young Park | 965d191 | 2013-02-08 11:37:16 -0800 | [diff] [blame] | 117 | # sort the list to give the same sequence based on name |
| 118 | packages.sort() |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 119 | |
| 120 | plan = tools.TestPlan(packages) |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 121 | plan.Exclude('android\.car') |
Tsu Chiang Chuang | d4cce3b | 2011-05-12 12:19:54 -0700 | [diff] [blame] | 122 | plan.Exclude('android\.performance.*') |
Brian Muramatsu | 87ff4df | 2011-12-16 11:41:17 -0800 | [diff] [blame] | 123 | self.__WritePlan(plan, 'CTS') |
Brian Muramatsu | 89ae08c | 2012-01-03 10:55:02 -0800 | [diff] [blame] | 124 | self.__WritePlan(plan, 'CTS-TF') |
Tsu Chiang Chuang | d4cce3b | 2011-05-12 12:19:54 -0700 | [diff] [blame] | 125 | |
Keun young Park | d93d0d1 | 2013-01-10 14:11:35 -0800 | [diff] [blame] | 126 | plan = tools.TestPlan(packages) |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 127 | plan.Exclude('android\.car') |
Keun young Park | d93d0d1 | 2013-01-10 14:11:35 -0800 | [diff] [blame] | 128 | plan.Exclude('android\.performance.*') |
Guru Nagarajan | 55f10db | 2013-06-03 13:50:37 -0700 | [diff] [blame] | 129 | plan.Exclude('android\.media\.cts\.StreamingMediaPlayerTest.*') |
| 130 | # Test plan to not include media streaming tests |
| 131 | self.__WritePlan(plan, 'CTS-No-Media-Stream') |
| 132 | |
| 133 | plan = tools.TestPlan(packages) |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 134 | plan.Exclude('android\.car') |
Guru Nagarajan | 55f10db | 2013-06-03 13:50:37 -0700 | [diff] [blame] | 135 | plan.Exclude('android\.performance.*') |
Keun young Park | d93d0d1 | 2013-01-10 14:11:35 -0800 | [diff] [blame] | 136 | self.__WritePlan(plan, 'SDK') |
| 137 | |
Stuart Scott | f67280f | 2014-09-30 14:07:30 -0700 | [diff] [blame] | 138 | plan.Exclude(r'android\.signature') |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 139 | plan.Exclude(r'android\.core.*') |
| 140 | self.__WritePlan(plan, 'Android') |
| 141 | |
| 142 | plan = tools.TestPlan(packages) |
| 143 | plan.Include(r'android\.core\.tests.*') |
Stuart Scott | d17e97a | 2015-09-29 12:36:55 -0700 | [diff] [blame] | 144 | plan.Exclude(r'android\.core\.tests\.libcore\.package\.harmony*') |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 145 | self.__WritePlan(plan, 'Java') |
| 146 | |
Tsu Chiang Chuang | cf7ceab | 2012-10-24 16:48:03 -0700 | [diff] [blame] | 147 | # TODO: remove this once the tests are fixed and merged into Java plan above. |
| 148 | plan = tools.TestPlan(packages) |
Stuart Scott | d17e97a | 2015-09-29 12:36:55 -0700 | [diff] [blame] | 149 | plan.Include(r'android\.core\.tests\.libcore\.package\.harmony*') |
Tsu Chiang Chuang | cf7ceab | 2012-10-24 16:48:03 -0700 | [diff] [blame] | 150 | self.__WritePlan(plan, 'Harmony') |
| 151 | |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 152 | plan = tools.TestPlan(packages) |
Tsu Chiang Chuang | 9a223d7 | 2011-04-27 17:19:46 -0700 | [diff] [blame] | 153 | plan.Include(r'android\.core\.vm-tests-tf') |
| 154 | self.__WritePlan(plan, 'VM-TF') |
| 155 | |
| 156 | plan = tools.TestPlan(packages) |
Phil Dubach | 6068048 | 2009-08-19 10:13:23 -0700 | [diff] [blame] | 157 | plan.Include(r'android\.tests\.appsecurity') |
| 158 | self.__WritePlan(plan, 'AppSecurity') |
| 159 | |
Keun young Park | ff19417 | 2012-08-14 17:56:11 -0700 | [diff] [blame] | 160 | # hard-coded white list for PDK plan |
| 161 | plan.Exclude('.*') |
keunyoung | c767cba | 2013-04-03 14:50:58 -0700 | [diff] [blame] | 162 | plan.Include('android\.aadb') |
Keun young Park | ff19417 | 2012-08-14 17:56:11 -0700 | [diff] [blame] | 163 | plan.Include('android\.bluetooth') |
| 164 | plan.Include('android\.graphics.*') |
| 165 | plan.Include('android\.hardware') |
keunyoung | de51946 | 2013-03-21 12:06:42 -0700 | [diff] [blame] | 166 | plan.Include('android\.media') |
| 167 | plan.Exclude('android\.mediastress') |
Keun young Park | ff19417 | 2012-08-14 17:56:11 -0700 | [diff] [blame] | 168 | plan.Include('android\.net') |
| 169 | plan.Include('android\.opengl.*') |
| 170 | plan.Include('android\.renderscript') |
| 171 | plan.Include('android\.telephony') |
| 172 | plan.Include('android\.nativemedia.*') |
Stuart Scott | a132af6 | 2013-11-07 10:30:32 -0800 | [diff] [blame] | 173 | plan.Include('com\.android\.cts\..*')#TODO(stuartscott): Should PDK have all these? |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 174 | plan.Exclude('android\.car') |
Keun young Park | ff19417 | 2012-08-14 17:56:11 -0700 | [diff] [blame] | 175 | self.__WritePlan(plan, 'PDK') |
| 176 | |
Nicholas Sauer | 72632f9 | 2015-05-04 14:45:50 -0700 | [diff] [blame] | 177 | temporarily_known_failure_tests = BuildCtsTemporarilyKnownFailureList(); |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 178 | flaky_tests = BuildCtsFlakyTestList() |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 179 | releasekey_tests = BuildListForReleaseBuildTest() |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 180 | |
| 181 | # CTS Stable plan |
| 182 | plan = tools.TestPlan(packages) |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 183 | plan.Exclude('android\.car') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 184 | plan.Exclude(r'android\.browser') |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 185 | for package, test_list in flaky_tests.iteritems(): |
| 186 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 187 | for package, test_list in releasekey_tests.iteritems(): |
| 188 | plan.ExcludeTests(package, test_list) |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 189 | self.__WritePlan(plan, 'CTS-stable') |
| 190 | |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 191 | # CTS Flaky plan - list of tests known to be flaky in lab environment |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 192 | plan = tools.TestPlan(packages) |
| 193 | plan.Exclude('.*') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 194 | plan.Include(r'android\.browser') |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 195 | for package, test_list in flaky_tests.iteritems(): |
Unsuk Jung | b5153c4 | 2014-09-19 02:12:50 -0700 | [diff] [blame] | 196 | plan.Include(package+'$') |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 197 | plan.IncludeTests(package, test_list) |
| 198 | self.__WritePlan(plan, 'CTS-flaky') |
| 199 | |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 200 | small_tests = BuildAospSmallSizeTestList() |
| 201 | medium_tests = BuildAospMediumSizeTestList() |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 202 | new_test_packages = BuildCtsVettedNewPackagesList() |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 203 | |
| 204 | # CTS - sub plan for public, small size tests |
| 205 | plan = tools.TestPlan(packages) |
| 206 | plan.Exclude('.*') |
| 207 | for package, test_list in small_tests.iteritems(): |
| 208 | plan.Include(package+'$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 209 | plan.Exclude(r'android\.browser') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 210 | for package, test_list in flaky_tests.iteritems(): |
| 211 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 212 | for package, test_list in releasekey_tests.iteritems(): |
| 213 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 214 | self.__WritePlan(plan, 'CTS-kitkat-small') |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 215 | self.__WritePlan(plan, 'CTS-public-small') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 216 | |
| 217 | # CTS - sub plan for public, medium size tests |
| 218 | plan = tools.TestPlan(packages) |
| 219 | plan.Exclude('.*') |
| 220 | for package, test_list in medium_tests.iteritems(): |
| 221 | plan.Include(package+'$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 222 | plan.Exclude(r'android\.browser') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 223 | for package, test_list in flaky_tests.iteritems(): |
| 224 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 225 | for package, test_list in releasekey_tests.iteritems(): |
| 226 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 227 | self.__WritePlan(plan, 'CTS-kitkat-medium') |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 228 | self.__WritePlan(plan, 'CTS-public-medium') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 229 | |
| 230 | # CTS - sub plan for hardware tests which is public, large |
| 231 | plan = tools.TestPlan(packages) |
| 232 | plan.Exclude('.*') |
| 233 | plan.Include(r'android\.hardware$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 234 | plan.Exclude(r'android\.browser') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 235 | for package, test_list in flaky_tests.iteritems(): |
| 236 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 237 | for package, test_list in releasekey_tests.iteritems(): |
| 238 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 239 | self.__WritePlan(plan, 'CTS-hardware') |
| 240 | |
Yin-Chia Yeh | 96f4d40 | 2015-10-29 17:53:39 -0700 | [diff] [blame] | 241 | # CTS - sub plan for camera tests which is public, large |
| 242 | plan = tools.TestPlan(packages) |
| 243 | plan.Exclude('.*') |
| 244 | plan.Include(r'android\.camera$') |
| 245 | misc_camera_tests = BuildCtsMiscCameraList() |
| 246 | for package, test_list in misc_camera_tests.iteritems(): |
| 247 | plan.Include(package+'$') |
| 248 | plan.IncludeTests(package, test_list) |
| 249 | for package, test_list in flaky_tests.iteritems(): |
| 250 | plan.ExcludeTests(package, test_list) |
| 251 | for package, test_list in releasekey_tests.iteritems(): |
| 252 | plan.ExcludeTests(package, test_list) |
| 253 | self.__WritePlan(plan, 'CTS-camera') |
| 254 | |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 255 | # CTS - sub plan for media tests which is public, large |
| 256 | plan = tools.TestPlan(packages) |
| 257 | plan.Exclude('.*') |
| 258 | plan.Include(r'android\.media$') |
Unsuk Jung | fd4955a | 2014-10-21 18:11:48 -0700 | [diff] [blame] | 259 | plan.Include(r'android\.view$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 260 | plan.Exclude(r'android\.browser') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 261 | for package, test_list in flaky_tests.iteritems(): |
| 262 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 263 | for package, test_list in releasekey_tests.iteritems(): |
| 264 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 265 | self.__WritePlan(plan, 'CTS-media') |
| 266 | |
| 267 | # CTS - sub plan for mediastress tests which is public, large |
| 268 | plan = tools.TestPlan(packages) |
| 269 | plan.Exclude('.*') |
| 270 | plan.Include(r'android\.mediastress$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 271 | plan.Exclude(r'android\.browser') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 272 | for package, test_list in flaky_tests.iteritems(): |
| 273 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 274 | for package, test_list in releasekey_tests.iteritems(): |
| 275 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 276 | self.__WritePlan(plan, 'CTS-mediastress') |
| 277 | |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 278 | # CTS - sub plan for new tests that is vetted for L launch |
| 279 | plan = tools.TestPlan(packages) |
| 280 | plan.Exclude('.*') |
| 281 | for package, test_list in new_test_packages.iteritems(): |
| 282 | plan.Include(package+'$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 283 | plan.Exclude(r'android\.browser') |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 284 | for package, test_list in flaky_tests.iteritems(): |
| 285 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 286 | for package, test_list in releasekey_tests.iteritems(): |
| 287 | plan.ExcludeTests(package, test_list) |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 288 | self.__WritePlan(plan, 'CTS-l-tests') |
| 289 | |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 290 | # CTS - sub plan for tests in drawelement packages |
| 291 | plan = tools.TestPlan(packages) |
| 292 | plan.Exclude('.*') |
| 293 | plan.Include(r'com\.drawelements\.') |
Kalle Raita | 30e3acc | 2015-11-25 10:46:01 -0800 | [diff] [blame] | 294 | plan.IncludeTests('com.drawelements.deqp.egl', ReadDeqpTestList(self.test_root, 'mnc/egl-master.txt')) |
| 295 | plan.IncludeTests('com.drawelements.deqp.gles2', ReadDeqpTestList(self.test_root, 'mnc/gles2-master.txt')) |
| 296 | plan.IncludeTests('com.drawelements.deqp.gles3', ReadDeqpTestList(self.test_root, 'mnc/gles3-master.txt')) |
| 297 | plan.IncludeTests('com.drawelements.deqp.gles31', ReadDeqpTestList(self.test_root, 'mnc/gles31-master.txt')) |
Pyry Haulos | e793db1 | 2015-07-27 11:09:55 -0700 | [diff] [blame] | 298 | self.__WritePlan(plan, 'CTS-DEQP') |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 299 | |
Kalle Raita | 30e3acc | 2015-11-25 10:46:01 -0800 | [diff] [blame] | 300 | plan = tools.TestPlan(packages) |
| 301 | plan.Exclude('.*') |
| 302 | plan.Include(r'com\.drawelements\.') |
| 303 | plan.ExcludeTests('com.drawelements.deqp.egl', ReadDeqpTestList(self.test_root, 'mnc/egl-master.txt')) |
| 304 | plan.ExcludeTests('com.drawelements.deqp.gles2', ReadDeqpTestList(self.test_root, 'mnc/gles2-master.txt')) |
| 305 | plan.ExcludeTests('com.drawelements.deqp.gles3', ReadDeqpTestList(self.test_root, 'mnc/gles3-master.txt')) |
| 306 | plan.ExcludeTests('com.drawelements.deqp.gles31', ReadDeqpTestList(self.test_root, 'mnc/gles31-master.txt')) |
| 307 | self.__WritePlan(plan, 'CTS-DEQP-for-next-rel') |
| 308 | |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 309 | # CTS - sub plan for new test packages added for staging |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 310 | plan = tools.TestPlan(packages) |
| 311 | for package, test_list in small_tests.iteritems(): |
| 312 | plan.Exclude(package+'$') |
| 313 | for package, test_list in medium_tests.iteritems(): |
| 314 | plan.Exclude(package+'$') |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 315 | for package, tests_list in new_test_packages.iteritems(): |
| 316 | plan.Exclude(package+'$') |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 317 | plan.Exclude(r'com\.drawelements\.') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 318 | plan.Exclude(r'android\.hardware$') |
| 319 | plan.Exclude(r'android\.media$') |
Unsuk Jung | fd4955a | 2014-10-21 18:11:48 -0700 | [diff] [blame] | 320 | plan.Exclude(r'android\.view$') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 321 | plan.Exclude(r'android\.mediastress$') |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 322 | plan.Exclude(r'android\.browser') |
Guang Zhu | 2d8a270 | 2016-03-19 19:53:43 -0700 | [diff] [blame] | 323 | plan.Exclude('android\.car') |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 324 | for package, test_list in flaky_tests.iteritems(): |
| 325 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 326 | for package, test_list in releasekey_tests.iteritems(): |
| 327 | plan.ExcludeTests(package, test_list) |
Unsuk Jung | 0a99c97 | 2015-09-02 15:28:15 -0700 | [diff] [blame] | 328 | self.__WritePlan(plan, 'CTS-m-tests') |
| 329 | |
| 330 | |
| 331 | # CTS - sub plan for new test packages added for staging |
| 332 | plan = tools.TestPlan(packages) |
| 333 | plan.Exclude('.*') |
| 334 | for package, test_list in temporarily_known_failure_tests.iteritems(): |
| 335 | plan.Include(package+'$') |
| 336 | plan.IncludeTests(package, test_list) |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 337 | self.__WritePlan(plan, 'CTS-staging') |
| 338 | |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 339 | plan = tools.TestPlan(packages) |
| 340 | plan.Exclude('.*') |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 341 | self.__WritePlan(plan, 'CTS-webview') |
| 342 | |
Daniel Xie | 8a532e5 | 2015-12-30 11:25:25 -0800 | [diff] [blame] | 343 | # CTS - sub plan for Security |
| 344 | plan = tools.TestPlan(packages) |
| 345 | plan.Exclude('.*') |
| 346 | plan.Include(r'android\.security$') |
| 347 | plan.Include('android\.host\.jdwpsecurity$') |
Selim Gurun | 364fd16 | 2016-02-19 17:41:52 -0800 | [diff] [blame] | 348 | plan.Include('android\.host\.abioverride$') |
Daniel Xie | 8a532e5 | 2015-12-30 11:25:25 -0800 | [diff] [blame] | 349 | self.__WritePlan(plan, 'Security') |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 350 | |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 351 | def BuildAospMediumSizeTestList(): |
| 352 | """ Construct a defaultdic that lists package names of medium tests |
| 353 | already published to aosp. """ |
| 354 | return { |
| 355 | 'android.app' : [], |
| 356 | 'android.core.tests.libcore.package.libcore' : [], |
| 357 | 'android.core.tests.libcore.package.org' : [], |
| 358 | 'android.core.vm-tests-tf' : [], |
| 359 | 'android.dpi' : [], |
| 360 | 'android.host.security' : [], |
| 361 | 'android.net' : [], |
| 362 | 'android.os' : [], |
Unsuk Jung | 2e4e929 | 2014-10-09 02:20:44 -0700 | [diff] [blame] | 363 | 'android.permission2' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 364 | 'android.security' : [], |
| 365 | 'android.telephony' : [], |
| 366 | 'android.webkit' : [], |
| 367 | 'android.widget' : [], |
Stuart Scott | 2c993ed | 2015-09-14 13:58:31 -0700 | [diff] [blame] | 368 | 'android.browser' : []} |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 369 | |
| 370 | def BuildAospSmallSizeTestList(): |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 371 | """ Construct a default dict that lists packages names of small tests |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 372 | already published to aosp. """ |
| 373 | return { |
| 374 | 'android.aadb' : [], |
| 375 | 'android.acceleration' : [], |
| 376 | 'android.accessibility' : [], |
| 377 | 'android.accessibilityservice' : [], |
| 378 | 'android.accounts' : [], |
| 379 | 'android.admin' : [], |
| 380 | 'android.animation' : [], |
Aaron Holden | c7f3b25 | 2015-10-20 11:48:37 -0700 | [diff] [blame] | 381 | 'android.appsecurity' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 382 | 'android.bionic' : [], |
| 383 | 'android.bluetooth' : [], |
| 384 | 'android.calendarcommon' : [], |
| 385 | 'android.content' : [], |
| 386 | 'android.core.tests.libcore.package.com' : [], |
| 387 | 'android.core.tests.libcore.package.conscrypt' : [], |
| 388 | 'android.core.tests.libcore.package.dalvik' : [], |
| 389 | 'android.core.tests.libcore.package.sun' : [], |
| 390 | 'android.core.tests.libcore.package.tests' : [], |
| 391 | 'android.database' : [], |
Stuart Scott | 5d50999 | 2015-09-15 10:56:10 -0700 | [diff] [blame] | 392 | 'android.dram' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 393 | 'android.dreams' : [], |
| 394 | 'android.drm' : [], |
| 395 | 'android.effect' : [], |
Stuart Scott | e4036fe | 2015-09-15 11:36:43 -0700 | [diff] [blame] | 396 | 'android.filesystem' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 397 | 'android.gesture' : [], |
| 398 | 'android.graphics' : [], |
| 399 | 'android.graphics2' : [], |
| 400 | 'android.jni' : [], |
| 401 | 'android.keystore' : [], |
| 402 | 'android.location' : [], |
| 403 | 'android.nativemedia.sl' : [], |
| 404 | 'android.nativemedia.xa' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 405 | 'android.ndef' : [], |
| 406 | 'android.opengl' : [], |
| 407 | 'android.openglperf' : [], |
| 408 | 'android.permission' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 409 | 'android.preference' : [], |
| 410 | 'android.preference2' : [], |
| 411 | 'android.provider' : [], |
| 412 | 'android.renderscript' : [], |
| 413 | 'android.rscpp' : [], |
| 414 | 'android.rsg' : [], |
| 415 | 'android.sax' : [], |
Stuart Scott | d2624e9 | 2016-01-06 14:20:03 -0800 | [diff] [blame] | 416 | 'android.server' : [], |
Stuart Scott | f67280f | 2014-09-30 14:07:30 -0700 | [diff] [blame] | 417 | 'android.signature' : [], |
Aaron Holden | ecda1b3 | 2015-10-15 12:23:21 -0700 | [diff] [blame] | 418 | 'android.simplecpu' : [], |
Yabin Cui | 33a0762 | 2016-03-02 14:02:34 -0800 | [diff] [blame] | 419 | 'android.simpleperf' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 420 | 'android.speech' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 421 | 'android.text' : [], |
| 422 | 'android.textureview' : [], |
| 423 | 'android.theme' : [], |
| 424 | 'android.usb' : [], |
| 425 | 'android.util' : [], |
Aaron Holden | 24fd578 | 2015-10-15 16:30:44 -0700 | [diff] [blame] | 426 | 'android.video' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 427 | 'com.android.cts.jank' : [], |
Guang Zhu | cf5c254 | 2015-03-09 23:13:27 -0700 | [diff] [blame] | 428 | 'com.android.cts.jank2' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 429 | 'com.android.cts.opengl' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 430 | 'com.android.cts.ui' : [], |
| 431 | 'com.android.cts.uihost' : [], |
Unsuk Jung | 8398ab8 | 2014-09-19 03:26:39 -0700 | [diff] [blame] | 432 | 'zzz.android.monkey' : []} |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 433 | |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 434 | def BuildCtsVettedNewPackagesList(): |
| 435 | """ Construct a defaultdict that maps package names that is vetted for L. """ |
| 436 | return { |
| 437 | 'android.JobScheduler' : [], |
| 438 | 'android.core.tests.libcore.package.harmony_annotation' : [], |
| 439 | 'android.core.tests.libcore.package.harmony_beans' : [], |
| 440 | 'android.core.tests.libcore.package.harmony_java_io' : [], |
| 441 | 'android.core.tests.libcore.package.harmony_java_lang' : [], |
| 442 | 'android.core.tests.libcore.package.harmony_java_math' : [], |
| 443 | 'android.core.tests.libcore.package.harmony_java_net' : [], |
| 444 | 'android.core.tests.libcore.package.harmony_java_nio' : [], |
| 445 | 'android.core.tests.libcore.package.harmony_java_util' : [], |
| 446 | 'android.core.tests.libcore.package.harmony_java_text' : [], |
| 447 | 'android.core.tests.libcore.package.harmony_javax_security' : [], |
| 448 | 'android.core.tests.libcore.package.harmony_logging' : [], |
| 449 | 'android.core.tests.libcore.package.harmony_prefs' : [], |
| 450 | 'android.core.tests.libcore.package.harmony_sql' : [], |
| 451 | 'android.core.tests.libcore.package.jsr166' : [], |
| 452 | 'android.core.tests.libcore.package.okhttp' : [], |
| 453 | 'android.display' : [], |
| 454 | 'android.host.theme' : [], |
| 455 | 'android.jdwp' : [], |
| 456 | 'android.location2' : [], |
| 457 | 'android.print' : [], |
| 458 | 'android.renderscriptlegacy' : [], |
| 459 | 'android.signature' : [], |
| 460 | 'android.tv' : [], |
| 461 | 'android.uiautomation' : [], |
Bo Liu | c30bdbc | 2015-05-18 14:15:15 -0700 | [diff] [blame] | 462 | 'android.uirendering' : []} |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 463 | |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 464 | def BuildListForReleaseBuildTest(): |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 465 | """ Construct a defaultdict that maps package name to a list of tests |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 466 | that are expected to pass only when running against a user/release-key build. """ |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 467 | return { |
| 468 | 'android.app' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 469 | 'android.app.cts.ActivityManagerTest#testIsRunningInTestHarness',], |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 470 | 'android.dpi' : [ |
| 471 | 'android.dpi.cts.DefaultManifestAttributesSdkTest#testPackageHasExpectedSdkVersion',], |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 472 | 'android.host.security' : [ |
| 473 | 'android.cts.security.SELinuxHostTest#testAllEnforcing', |
| 474 | 'android.cts.security.SELinuxHostTest#testSuDomain',], |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 475 | 'android.os' : [ |
| 476 | 'android.os.cts.BuildVersionTest#testReleaseVersion', |
| 477 | 'android.os.cts.BuildTest#testIsSecureUserBuild',], |
| 478 | 'android.security' : [ |
| 479 | 'android.security.cts.BannedFilesTest#testNoSu', |
| 480 | 'android.security.cts.BannedFilesTest#testNoSuInPath', |
| 481 | 'android.security.cts.PackageSignatureTest#testPackageSignatures', |
| 482 | 'android.security.cts.SELinuxDomainTest#testSuDomain',], |
| 483 | '' : []} |
| 484 | |
| 485 | def BuildCtsFlakyTestList(): |
| 486 | """ Construct a defaultdict that maps package name to a list of tests |
| 487 | that flaky during dev cycle and cause other subsequent tests to fail. """ |
| 488 | return { |
Yin-Chia Yeh | 96f4d40 | 2015-10-29 17:53:39 -0700 | [diff] [blame] | 489 | 'android.camera' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 490 | 'android.hardware.cts.CameraTest#testVideoSnapshot', |
| 491 | 'android.hardware.cts.CameraGLTest#testCameraToSurfaceTextureMetadata', |
| 492 | 'android.hardware.cts.CameraGLTest#testSetPreviewTextureBothCallbacks', |
| 493 | 'android.hardware.cts.CameraGLTest#testSetPreviewTexturePreviewCallback',], |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 494 | 'android.media' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 495 | 'android.media.cts.DecoderTest#testCodecResetsH264WithSurface', |
| 496 | 'android.media.cts.StreamingMediaPlayerTest#testHLS',], |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 497 | 'android.net' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 498 | 'android.net.cts.ConnectivityManagerTest#testStartUsingNetworkFeature_enableHipri', |
| 499 | 'android.net.cts.DnsTest#testDnsWorks', |
| 500 | 'android.net.cts.SSLCertificateSocketFactoryTest#testCreateSocket', |
| 501 | 'android.net.cts.SSLCertificateSocketFactoryTest#test_createSocket_bind', |
| 502 | 'android.net.cts.SSLCertificateSocketFactoryTest#test_createSocket_simple', |
| 503 | 'android.net.cts.SSLCertificateSocketFactoryTest#test_createSocket_wrapping', |
| 504 | 'android.net.cts.TrafficStatsTest#testTrafficStatsForLocalhost', |
| 505 | 'android.net.wifi.cts.NsdManagerTest#testAndroidTestCaseSetupProperly',], |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 506 | 'android.security' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 507 | 'android.security.cts.ListeningPortsTest#testNoRemotelyAccessibleListeningUdp6Ports', |
Unsuk Jung | 1345d3d | 2015-04-24 12:14:59 -0700 | [diff] [blame] | 508 | 'android.security.cts.ListeningPortsTest#testNoRemotelyAccessibleListeningUdpPorts',], |
Nicholas Sauer | 471c601 | 2014-05-28 15:28:28 -0700 | [diff] [blame] | 509 | 'android.webkit' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 510 | 'android.webkit.cts.WebViewClientTest#testOnUnhandledKeyEvent',], |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 511 | 'com.android.cts.filesystemperf' : [ |
Nicholas Sauer | 42b1b61 | 2015-04-24 15:58:47 -0700 | [diff] [blame] | 512 | 'com.android.cts.filesystemperf.RandomRWTest#testRandomRead', |
| 513 | 'com.android.cts.filesystemperf.RandomRWTest#testRandomUpdate',], |
Guang Zhu | 80f667f | 2015-01-15 16:40:46 -0800 | [diff] [blame] | 514 | '' : []} |
Unsuk Jung | 2a692d1 | 2013-09-29 20:57:32 -0700 | [diff] [blame] | 515 | |
Nicholas Sauer | 72632f9 | 2015-05-04 14:45:50 -0700 | [diff] [blame] | 516 | def BuildCtsTemporarilyKnownFailureList(): |
| 517 | """ Construct a defaultdict that maps package name to a list of tests |
| 518 | that are known failures during dev cycle but expected to be fixed before launch """ |
| 519 | return { |
Unsuk Jung | 0a99c97 | 2015-09-02 15:28:15 -0700 | [diff] [blame] | 520 | 'android.alarmclock' : [ |
| 521 | 'android.alarmclock.cts.DismissAlarmTest#testAll', |
| 522 | 'android.alarmclock.cts.SetAlarmTest#testAll', |
| 523 | 'android.alarmclock.cts.SnoozeAlarmTest#testAll', |
| 524 | ], |
Unsuk Jung | 0a99c97 | 2015-09-02 15:28:15 -0700 | [diff] [blame] | 525 | 'android.dumpsys' : [ |
| 526 | 'android.dumpsys.cts.DumpsysHostTest#testBatterystatsOutput', |
| 527 | 'android.dumpsys.cts.DumpsysHostTest#testGfxinfoFramestats', |
| 528 | ], |
| 529 | 'android.telecom' : [ |
| 530 | 'android.telecom.cts.ExtendedInCallServiceTest#testAddNewOutgoingCallAndThenDisconnect', |
| 531 | 'android.telecom.cts.RemoteConferenceTest#testRemoteConferenceCallbacks_ConferenceableConnections', |
| 532 | ], |
| 533 | 'android.transition' : [ |
| 534 | 'android.transition.cts.ChangeScrollTest#testChangeScroll', |
| 535 | ], |
| 536 | 'android.voicesettings' : [ |
| 537 | 'android.voicesettings.cts.ZenModeTest#testAll', |
| 538 | ], |
Aaron Holden | ea930f8 | 2015-09-21 10:35:42 -0700 | [diff] [blame] | 539 | 'android.systemui.cts' : [ |
| 540 | 'android.systemui.cts.LightStatusBarTests#testLightStatusBarIcons', |
Adrian Roos | d052b58 | 2015-08-27 19:06:39 -0700 | [diff] [blame] | 541 | ], |
Unsuk Jung | 0a99c97 | 2015-09-02 15:28:15 -0700 | [diff] [blame] | 542 | 'com.android.cts.app.os' : [ |
| 543 | 'com.android.cts.app.os.OsHostTests#testNonExportedActivities', |
| 544 | ], |
Alex Chau | 8b5df14 | 2015-08-10 18:11:02 +0100 | [diff] [blame] | 545 | 'com.android.cts.devicepolicy' : [ |
| 546 | 'com.android.cts.devicepolicy.MixedDeviceOwnerTest#testPackageInstallUserRestrictions', |
| 547 | 'com.android.cts.devicepolicy.MixedProfileOwnerTest#testPackageInstallUserRestrictions', |
| 548 | ], |
Nicholas Sauer | 72632f9 | 2015-05-04 14:45:50 -0700 | [diff] [blame] | 549 | '' : []} |
| 550 | |
Yin-Chia Yeh | 96f4d40 | 2015-10-29 17:53:39 -0700 | [diff] [blame] | 551 | def BuildCtsMiscCameraList(): |
| 552 | """ Construct a defaultdict that maps package name to a list of tests |
| 553 | that are relevant to camera but does not reside in camera test package """ |
| 554 | return { |
| 555 | 'android.app' : [ |
| 556 | 'android.app.cts.SystemFeaturesTest#testCameraFeatures', |
| 557 | ], |
| 558 | 'android.permission' : [ |
| 559 | 'android.permission.cts.CameraPermissionTest', |
| 560 | 'android.permission.cts.Camera2PermissionTest', |
| 561 | ], |
| 562 | '' : []} |
| 563 | |
Brian Muramatsu | 9157e0a | 2011-04-05 18:06:15 -0700 | [diff] [blame] | 564 | def LogGenerateDescription(name): |
| 565 | print 'Generating test description for package %s' % name |
| 566 | |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 567 | if __name__ == '__main__': |
| 568 | builder = CtsBuilder(sys.argv) |
Keun young Park | d93d0d1 | 2013-01-10 14:11:35 -0800 | [diff] [blame] | 569 | result = builder.GenerateTestDescriptions() |
| 570 | if result != 0: |
| 571 | sys.exit(result) |
Phil Dubach | 0d6ef06 | 2009-08-12 18:13:16 -0700 | [diff] [blame] | 572 | builder.GenerateTestPlans() |