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

Side by Side Diff: Tools/Scripts/webkitpy/w3c/test_importer.py

Issue 727883002: update-w3c-deps import using blink 7f8c8ee3e30dc15b7b821c627fc7ac32331d2253: (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 6 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « LayoutTests/imported/web-platform-tests/server-side.md ('k') | no next file » | 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 Adobe Systems Incorporated. All rights reserved. 1 # Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
2 # 2 #
3 # Redistribution and use in source and binary forms, with or without 3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions 4 # modification, are permitted provided that the following conditions
5 # are met: 5 # are met:
6 # 6 #
7 # 1. Redistributions of source code must retain the above 7 # 1. Redistributions of source code must retain the above
8 # copyright notice, this list of conditions and the following 8 # copyright notice, this list of conditions and the following
9 # disclaimer. 9 # disclaimer.
10 # 2. Redistributions in binary form must reproduce the above 10 # 2. Redistributions in binary form must reproduce the above
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 _log.info(" pruning %s" % path_base) 212 _log.info(" pruning %s" % path_base)
213 self.filesystem.rmtree(path_full) 213 self.filesystem.rmtree(path_full)
214 else: 214 else:
215 _log.info(" skipping %s" % path_base) 215 _log.info(" skipping %s" % path_base)
216 216
217 217
218 copy_list = [] 218 copy_list = []
219 219
220 for filename in files: 220 for filename in files:
221 path_full = self.filesystem.join(root, filename) 221 path_full = self.filesystem.join(root, filename)
222 path_base = path_full.replace(self.layout_tests_dir + '/', '') 222 path_base = path_full.replace(directory + '/', '')
223 path_base = self.destination_directory.replace(self.layout_tests _dir + '/', '') + '/' + path_base
223 if path_base in paths_to_skip: 224 if path_base in paths_to_skip:
224 if not self.options.dry_run and self.import_in_place: 225 if not self.options.dry_run and self.import_in_place:
225 _log.info(" pruning %s" % path_base) 226 _log.info(" pruning %s" % path_base)
226 self.filesystem.remove(path_full) 227 self.filesystem.remove(path_full)
227 continue 228 continue
228 else: 229 else:
229 continue 230 continue
230 # FIXME: This block should really be a separate function, but th e early-continues make that difficult. 231 # FIXME: This block should really be a separate function, but th e early-continues make that difficult.
231 232
232 if filename.startswith('.') or filename.endswith('.pl'): 233 if filename.startswith('.') or filename.endswith('.pl'):
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 """ Creates a destination directory that mirrors that of the source dire ctory """ 397 """ Creates a destination directory that mirrors that of the source dire ctory """
397 398
398 new_subpath = self.dir_to_import[len(self.top_of_repo):] 399 new_subpath = self.dir_to_import[len(self.top_of_repo):]
399 400
400 destination_directory = os.path.join(self.destination_directory, new_sub path) 401 destination_directory = os.path.join(self.destination_directory, new_sub path)
401 402
402 if not os.path.exists(destination_directory): 403 if not os.path.exists(destination_directory):
403 os.makedirs(destination_directory) 404 os.makedirs(destination_directory)
404 405
405 _log.info('Tests will be imported into: %s', destination_directory) 406 _log.info('Tests will be imported into: %s', destination_directory)
OLDNEW
« no previous file with comments | « LayoutTests/imported/web-platform-tests/server-side.md ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698