| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 2 # Copyright (c) 2012 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 """Script for a testing an existing SDK. | 6 """Script for a testing an existing SDK. |
| 7 | 7 |
| 8 This script is normally run immediately after build_sdk.py. | 8 This script is normally run immediately after build_sdk.py. |
| 9 """ | 9 """ |
| 10 | 10 |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 # compiler. | 119 # compiler. |
| 120 if getos.GetPlatform() == 'linux': | 120 if getos.GetPlatform() == 'linux': |
| 121 if sanitizer: | 121 if sanitizer: |
| 122 configs = ('Debug',) | 122 configs = ('Debug',) |
| 123 for config in configs: | 123 for config in configs: |
| 124 RunTest(location, 'linux', config) | 124 RunTest(location, 'linux', config) |
| 125 | 125 |
| 126 if sanitizer: | 126 if sanitizer: |
| 127 continue | 127 continue |
| 128 | 128 |
| 129 for toolchain in ('clang-newlib', 'newlib', 'glibc', 'pnacl'): | 129 for toolchain in ('clang-newlib', 'glibc', 'pnacl'): |
| 130 for arch in archs: | 130 for arch in archs: |
| 131 # TODO(sbc): Remove this once we get elf_loader.nexe added to the SDK | 131 # TODO(sbc): Remove this once we get elf_loader.nexe added to the SDK |
| 132 if toolchain == 'glibc' and arch == 'arm': | 132 if toolchain == 'glibc' and arch == 'arm': |
| 133 continue | 133 continue |
| 134 for config in configs: | 134 for config in configs: |
| 135 RunTest(location, toolchain, config, arch) | 135 RunTest(location, toolchain, config, arch) |
| 136 | 136 |
| 137 | 137 |
| 138 def StepRunBrowserTests(toolchains, experimental): | 138 def StepRunBrowserTests(toolchains, experimental): |
| 139 buildbot_common.BuildStep('Run Tests') | 139 buildbot_common.BuildStep('Run Tests') |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 try: | 177 try: |
| 178 import optcomplete | 178 import optcomplete |
| 179 optcomplete.autocomplete(parser) | 179 optcomplete.autocomplete(parser) |
| 180 except ImportError: | 180 except ImportError: |
| 181 pass | 181 pass |
| 182 | 182 |
| 183 options = parser.parse_args(args) | 183 options = parser.parse_args(args) |
| 184 | 184 |
| 185 pepper_ver = str(int(build_version.ChromeMajorVersion())) | 185 pepper_ver = str(int(build_version.ChromeMajorVersion())) |
| 186 pepperdir = os.path.join(OUT_DIR, 'pepper_' + pepper_ver) | 186 pepperdir = os.path.join(OUT_DIR, 'pepper_' + pepper_ver) |
| 187 toolchains = ['clang-newlib', 'newlib', 'glibc', 'pnacl'] | 187 toolchains = ['clang-newlib', 'glibc', 'pnacl'] |
| 188 toolchains.append(getos.GetPlatform()) | 188 toolchains.append(getos.GetPlatform()) |
| 189 | 189 |
| 190 if options.verbose: | 190 if options.verbose: |
| 191 build_projects.verbose = True | 191 build_projects.verbose = True |
| 192 | 192 |
| 193 phases = [ | 193 phases = [ |
| 194 ('build_examples', StepBuildExamples, pepperdir), | 194 ('build_examples', StepBuildExamples, pepperdir), |
| 195 ('copy_tests', StepCopyTests, pepperdir, toolchains, options.experimental), | 195 ('copy_tests', StepCopyTests, pepperdir, toolchains, options.experimental), |
| 196 ('build_tests', StepBuildTests, pepperdir), | 196 ('build_tests', StepBuildTests, pepperdir), |
| 197 ('sel_ldr_tests', StepRunSelLdrTests, pepperdir, None), | 197 ('sel_ldr_tests', StepRunSelLdrTests, pepperdir, None), |
| (...skipping 28 matching lines...) Expand all Loading... |
| 226 phase_func(*phase_args) | 226 phase_func(*phase_args) |
| 227 | 227 |
| 228 return 0 | 228 return 0 |
| 229 | 229 |
| 230 | 230 |
| 231 if __name__ == '__main__': | 231 if __name__ == '__main__': |
| 232 try: | 232 try: |
| 233 sys.exit(main(sys.argv[1:])) | 233 sys.exit(main(sys.argv[1:])) |
| 234 except KeyboardInterrupt: | 234 except KeyboardInterrupt: |
| 235 buildbot_common.ErrorExit('test_sdk: interrupted') | 235 buildbot_common.ErrorExit('test_sdk: interrupted') |
| OLD | NEW |