Changeset 170062 in webkit
- Timestamp:
- Jun 17, 2014, 11:02:08 AM (11 years ago)
- Location:
- trunk/Tools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r170058 r170062 1 2014-06-17 Rebecca Hauck <rhauck@adobe.com> 2 3 Update import-w3c-tests to reflect current W3C test repo directory structure 4 https://bugs.webkit.org/show_bug.cgi?id=133460 5 6 Reviewed by Bem Jones-Bey. 7 8 Removed all references to test status, which are no longer reflected in the 9 directory names in the W3C CSS test repo. No tests are required for this 10 change, the existing tests pass. 11 12 * Scripts/webkitpy/w3c/test_importer.py: 13 (main): 14 (TestImporter.__init__): 15 (TestImporter.find_importable_tests): 16 (TestImporter.setup_destination_directory): 17 (TestImporter.write_import_log): 18 (TestImporter.update_test_status): Deleted. 19 1 20 2014-06-17 Carlos Alberto Lopez Perez <clopez@igalia.com> 2 21 -
trunk/Tools/Scripts/webkitpy/w3c/test_importer.py
r169369 r170062 35 35 This script will import the tests into WebKit following these rules: 36 36 37 - Only tests that are approved or officially submitted awaiting review are imported 38 39 - All tests are imported into LayoutTests/csswg 40 41 - If the tests are approved, they'll be imported into a directory tree that 42 mirrors the CSS Mercurial repo. For example, <csswg_repo_root>/approved/css2.1 is brought in 43 as LayoutTests/csswg/approved/css2.1, maintaining the entire directory structure under that 44 45 - If the tests are submitted, they'll maintain their directory structure under 46 LayoutTests/csswg. For example, everything under 47 <csswg_repo_root>/contributors/adobe/submitted is brought into 48 LayoutTests/csswg/contributors/adobe/submitted, mirroring its directory structure in the 49 csswg repo 50 51 - If the import directory specified is just a contributor folder, only the submitted folder 52 for that contributor is brought in. For example, to import all of Mozilla's tests, either 53 <csswg_repo_root>/contributors/mozilla or <csswg_repo_root>/contributors/mozilla/submitted 54 will work and are equivalent. 37 - All tests are imported into LayoutTests/w3c 38 39 - Tests will be imported into a directory tree that 40 mirrors the CSS Mercurial repo. For example, <csswg_repo_root>/css2.1 is brought in 41 as LayoutTests/csswg/css2.1, maintaining the entire directory structure under that 55 42 56 43 - By default, only reftests and jstest are imported. This can be overridden with a -a or --all … … 99 86 from webkitpy.w3c.test_converter import convert_for_webkit 100 87 101 102 TEST_STATUS_UNKNOWN = 'unknown'103 TEST_STATUS_APPROVED = 'approved'104 TEST_STATUS_SUBMITTED = 'submitted'105 VALID_TEST_STATUSES = [TEST_STATUS_APPROVED, TEST_STATUS_SUBMITTED]106 107 CONTRIBUTOR_DIR_NAME = 'contributors'108 109 88 CHANGESET_NOT_AVAILABLE = 'Not Available' 110 111 89 112 90 _log = logging.getLogger(__name__) … … 117 95 import_dir = args[0] 118 96 if len(args) == 1: 119 repo_dir_parts = [] 120 for part in import_dir.split(os.path.sep): 121 if part in VALID_TEST_STATUSES: 122 break 123 else: 124 repo_dir_parts.append(part) 125 repo_dir = os.path.sep.join(repo_dir_parts) 97 repo_dir = import_dir 126 98 else: 127 99 repo_dir = args[1] … … 188 160 189 161 self.changeset = CHANGESET_NOT_AVAILABLE 190 self.test_status = TEST_STATUS_UNKNOWN191 162 192 163 self.import_list = [] … … 212 183 jstests = 0 213 184 214 # "archive" and "data" dirs are internal csswg things that live in every approved directory. 215 # FIXME: skip 'incoming' tests for now, but we should rework the 'test_status' concept and 216 # support reading them as well. 217 DIRS_TO_SKIP = ('.git', '.hg', 'data', 'archive', 'incoming') 185 DIRS_TO_SKIP = ('.git', '.hg', 'work-in-progress', 'tools', 'support') 218 186 for d in DIRS_TO_SKIP: 219 187 if d in dirs: … … 385 353 386 354 def setup_destination_directory(self): 387 """ Creates a destination directory that mirrors that of the source approved or submitted directory """ 388 389 self.update_test_status() 390 391 start = self.source_directory.find(self.test_status) 355 """ Creates a destination directory that mirrors that of the source directory """ 356 392 357 new_subpath = self.source_directory[len(self.repo_dir):] 393 358 … … 398 363 399 364 _log.info('Tests will be imported into: %s', destination_directory) 400 401 def update_test_status(self):402 """ Sets the test status to either 'approved' or 'submitted' """403 404 status = TEST_STATUS_UNKNOWN405 406 directory_parts = self.source_directory.split(os.path.sep)407 for test_status in VALID_TEST_STATUSES:408 if test_status in directory_parts:409 status = test_status410 411 self.test_status = status412 365 413 366 def remove_deleted_files(self, import_directory, new_file_list): … … 449 402 import_log.write('Last Import: ' + now.strftime('%Y-%m-%d %H:%M') + '\n') 450 403 import_log.write('W3C Mercurial changeset: ' + self.changeset + '\n') 451 import_log.write('Test status at time of import: ' + self.test_status + '\n')452 404 import_log.write('------------------------------------------------------------------------\n') 453 405 import_log.write('Properties requiring vendor prefixes:\n')
Note:
See TracChangeset
for help on using the changeset viewer.