OLD | NEW |
1 #!/usr/bin/python | 1 #!/usr/bin/python |
2 | 2 |
3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
6 | 6 |
7 import optparse | 7 import optparse |
8 import os | 8 import os |
9 import re | 9 import re |
10 import sys | 10 import sys |
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
495 AUTest.use_delta_updates = options.delta | 495 AUTest.use_delta_updates = options.delta |
496 | 496 |
497 # Only run the test harness we care about. | 497 # Only run the test harness we care about. |
498 test_loader = unittest.TestLoader() | 498 test_loader = unittest.TestLoader() |
499 test_loader.testMethodPrefix = options.test_prefix | 499 test_loader.testMethodPrefix = options.test_prefix |
500 | 500 |
501 if options.type == 'vm': test_class = VirtualAUTest | 501 if options.type == 'vm': test_class = VirtualAUTest |
502 elif options.type == 'real': test_class = RealAUTest | 502 elif options.type == 'real': test_class = RealAUTest |
503 else: parser.error('Could not parse harness type %s.' % options.type) | 503 else: parser.error('Could not parse harness type %s.' % options.type) |
504 | 504 |
| 505 remote = options.remote |
| 506 |
505 test_suite = test_loader.loadTestsFromTestCase(test_class) | 507 test_suite = test_loader.loadTestsFromTestCase(test_class) |
506 test_result = unittest.TextTestRunner(verbosity=2).run(test_suite) | 508 test_result = unittest.TextTestRunner(verbosity=2).run(test_suite) |
507 | 509 |
508 if not test_result.wasSuccessful(): | 510 if not test_result.wasSuccessful(): |
509 Die('Test harness was not successful') | 511 Die('Test harness was not successful') |
OLD | NEW |