Chromium Code Reviews| Index: au_test_harness/cros_au_test_harness.py |
| diff --git a/au_test_harness/cros_au_test_harness.py b/au_test_harness/cros_au_test_harness.py |
| index dc6572ab807efc5e14559db30ca95ac7116196d6..ae344ace70c70d453862700b48af64593ef20810 100755 |
| --- a/au_test_harness/cros_au_test_harness.py |
| +++ b/au_test_harness/cros_au_test_harness.py |
| @@ -68,7 +68,18 @@ def _PregenerateUpdates(options): |
| command.append('--private_key=%s' % |
| cros_lib.ReinterpretPathForChroot(private_key_path)) |
| - return cros_lib.RunCommand(command, enter_chroot=True, print_cmd=True, |
| + if src: |
| + str = 'delta update payload from %s to %s' % (target, src) |
|
davidjames
2011/04/15 17:52:09
Can we use a different name for the variable? str
sosa
2011/04/18 21:12:44
Done.
|
| + else: |
| + str = 'full update payload to %s' % target |
| + |
| + if private_key_path: |
| + str = 'Generating a signed ' + str |
| + else: |
| + str = 'Generating an unsigned ' + str |
| + |
| + cros_lib.Info(str) |
| + return cros_lib.RunCommand(command, enter_chroot=True, print_cmd=False, |
| cwd=cros_lib.GetCrosUtilsPath(), |
| log_to_file=log_file, error_ok=True, |
| exit_code=True) |
| @@ -106,12 +117,11 @@ def _PregenerateUpdates(options): |
| # Use dummy class to mock out updates that would be run as part of a test. |
| test_suite = _PrepareTestSuite(options, use_dummy_worker=True) |
| - test_result = unittest.TextTestRunner(verbosity=0).run(test_suite) |
| + test_result = unittest.TextTestRunner().run(test_suite) |
| if not test_result.wasSuccessful(): |
| raise update_exception.UpdateException(1, |
| 'Error finding updates to generate.') |
| - cros_lib.Info('The following delta updates are required.') |
| update_ids = [] |
| jobs = [] |
| args = [] |
| @@ -126,7 +136,6 @@ def _PregenerateUpdates(options): |
| # TODO(sosa): Add private key as part of caching name once devserver can |
| # handle it its own cache. |
| update_id = dev_server_wrapper.GenerateUpdateId(target, src, key) |
| - print >> sys.stderr, 'AU: %s' % update_id |
| update_ids.append(update_id) |
| jobs.append(_GenerateVMUpdate) |
| args.append((target, src, key, log_file)) |
| @@ -162,7 +171,7 @@ def _RunTestsInParallel(options): |
| for test in test_suite: |
| test_name = test.id() |
| test_case = unittest.TestLoader().loadTestsFromName(test_name) |
| - threads.append(unittest.TextTestRunner(verbosity=2).run) |
| + threads.append(unittest.TextTestRunner().run) |
| args.append(test_case) |
| results = parallel_test_job.RunParallelJobs(options.jobs, threads, args) |
| @@ -269,7 +278,7 @@ def main(): |
| # TODO(sosa) - Take in a machine pool for a real test. |
| # Can't run in parallel with only one remote device. |
| test_suite = _PrepareTestSuite(options) |
| - test_result = unittest.TextTestRunner(verbosity=2).run(test_suite) |
| + test_result = unittest.TextTestRunner().run(test_suite) |
| if not test_result.wasSuccessful(): cros_lib.Die('Test harness failed.') |
| finally: |