Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 #!/usr/bin/env python | |
| 2 # Copyright 2016 The Chromium Authors. All rights reserved. | |
|
jeffcarp
2017/01/20 22:19:13
Should this be 2017 since it's a new file?
qyearsley
2017/01/20 23:22:42
Yeah!
| |
| 3 # Use of this source code is governed by a BSD-style license that can be | |
| 4 # found in the LICENSE file. | |
| 5 | |
| 6 """Exports local changes to web-platform-tests in Chromium to upstream repo. | |
| 7 | |
| 8 This script checks LayoutTests/external/wpt for changes that can be exported, | |
| 9 then creates a patch, and creates and lands a pull request for the upstream | |
| 10 repository. | |
| 11 """ | |
| 12 | |
| 13 import argparse | |
| 14 import logging | |
| 15 | |
| 16 from webkitpy.common.host import Host | |
| 17 from webkitpy.w3c.test_exporter import TestExporter | |
| 18 from webkitpy.w3c.wpt_github import WPTGitHub | |
| 19 | |
| 20 | |
| 21 _log = logging.getLogger(__name__) | |
| 22 | |
| 23 | |
| 24 def main(): | |
| 25 logging.basicConfig(level=logging.INFO, format='%(message)s') | |
| 26 | |
| 27 parser = argparse.ArgumentParser(description=__doc__) | |
| 28 parser.add_argument( | |
| 29 '--dry-run', action='store_true', | |
| 30 help='See what would be done without actually making a pull request.') | |
|
jeffcarp
2017/01/20 22:19:13
This only covers half of the use case - maybe add
qyearsley
2017/01/20 23:22:42
SGTM
| |
| 31 args = parser.parse_args() | |
| 32 | |
| 33 host = Host() | |
| 34 wpt_github = WPTGitHub(host) | |
| 35 test_exporter = TestExporter(host, wpt_github, dry_run=args.dry_run) | |
| 36 | |
| 37 test_exporter.run() | |
| 38 | |
| 39 | |
| 40 if __name__ == '__main__': | |
| 41 main() | |
|
jeffcarp
2017/01/20 22:19:13
2 spaces indentation here instead of 4
qyearsley
2017/01/20 23:22:42
Good catch
| |
| OLD | NEW |