Chromium Code Reviews| Index: ios/build/bots/scripts/test_runner.py |
| diff --git a/ios/build/bots/scripts/test_runner.py b/ios/build/bots/scripts/test_runner.py |
| index 6cc4fc4eef4292b7b8f3686404c55cedec4d3327..b57e54fe232beab7fa3a761431dcb19f27d630ac 100644 |
| --- a/ios/build/bots/scripts/test_runner.py |
| +++ b/ios/build/bots/scripts/test_runner.py |
| @@ -187,6 +187,13 @@ class TestRunner(object): |
| self.xcode_version = xcode_version |
| self.xctest_path = '' |
| + self.test_results = {} |
| + self.test_results['version'] = 3 |
| + self.test_results['path_delimiter'] = '.' |
| + self.test_results['seconds_since_epoch'] = int(time.time()) |
| + # This will be overwritten when the tests complete successfully. |
| + self.test_results['interrupted'] = True |
| + |
| if xctest: |
| plugins_dir = os.path.join(self.app_path, 'PlugIns') |
| if not os.path.exists(plugins_dir): |
| @@ -349,6 +356,21 @@ class TestRunner(object): |
| else: |
| raise |
| + # Build test_results.json |
|
lpromero
2017/01/10 14:34:04
Add a period.
rohitrao (ping after 24h)
2017/01/10 17:39:31
Done.
|
| + self.test_results['interrupted'] = result.crashed |
| + self.test_results['num_failures_by_type'] = { |
| + 'FAIL': len(failed) + len(flaked), |
| + 'PASS': len(passed), |
| + } |
|
lpromero
2017/01/10 14:34:04
Is this indent correct?
rohitrao (ping after 24h)
2017/01/10 17:39:31
Not sure, moved it out two.
|
| + tests = collections.OrderedDict() |
| + for test in passed: |
| + tests[test] = { 'expected': 'PASS', 'actual': 'PASS' } |
| + for test, _ in failed: |
| + tests[test] = { 'expected': 'PASS', 'actual': 'FAIL' } |
| + for test, _ in flaked: |
| + tests[test] = { 'expected': 'PASS', 'actual': 'FAIL' } |
| + self.test_results['tests'] = tests |
| + |
| self.logs['passed tests'] = passed |
| for test, log_lines in failed.iteritems(): |
| self.logs[test] = log_lines |