OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import collections | 6 import collections |
7 import glob | 7 import glob |
8 import hashlib | 8 import hashlib |
9 import json | 9 import json |
10 import os | 10 import os |
(...skipping 706 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
717 | 717 |
718 if args: | 718 if args: |
719 return sys.exit('Unused args %s' % args) | 719 return sys.exit('Unused args %s' % args) |
720 | 720 |
721 unknown_tests = set(options.test_filter) - VALID_TESTS | 721 unknown_tests = set(options.test_filter) - VALID_TESTS |
722 if unknown_tests: | 722 if unknown_tests: |
723 return sys.exit('Unknown tests %s' % list(unknown_tests)) | 723 return sys.exit('Unknown tests %s' % list(unknown_tests)) |
724 | 724 |
725 setattr(options, 'target', options.factory_properties.get('target', 'Debug')) | 725 setattr(options, 'target', options.factory_properties.get('target', 'Debug')) |
726 | 726 |
| 727 # pylint: disable=global-statement |
727 if options.chrome_output_dir: | 728 if options.chrome_output_dir: |
728 global CHROME_OUT_DIR | 729 global CHROME_OUT_DIR |
729 global LOGCAT_DIR | 730 global LOGCAT_DIR |
730 CHROME_OUT_DIR = options.chrome_output_dir | 731 CHROME_OUT_DIR = options.chrome_output_dir |
731 LOGCAT_DIR = os.path.join(CHROME_OUT_DIR, 'logcat') | 732 LOGCAT_DIR = os.path.join(CHROME_OUT_DIR, 'logcat') |
732 | 733 |
733 if options.coverage_bucket: | 734 if options.coverage_bucket: |
734 setattr(options, 'coverage_dir', | 735 setattr(options, 'coverage_dir', |
735 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) | 736 os.path.join(CHROME_OUT_DIR, options.target, 'coverage')) |
736 | 737 |
737 MainTestWrapper(options) | 738 MainTestWrapper(options) |
738 | 739 |
739 | 740 |
740 if __name__ == '__main__': | 741 if __name__ == '__main__': |
741 sys.exit(main(sys.argv)) | 742 sys.exit(main(sys.argv)) |
OLD | NEW |