| OLD | NEW |
| 1 # Copyright (C) 2012 Google Inc. All rights reserved. | 1 # Copyright (C) 2012 Google Inc. All rights reserved. |
| 2 # | 2 # |
| 3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
| 4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
| 5 # met: | 5 # met: |
| 6 # | 6 # |
| 7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
| 8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
| 9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
| 10 # copyright notice, this list of conditions and the following disclaimer | 10 # copyright notice, this list of conditions and the following disclaimer |
| (...skipping 246 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 257 absolute_path_to_trunk = filesystem.dirname(self._port.perf_tests_dir()) | 257 absolute_path_to_trunk = filesystem.dirname(self._port.perf_tests_dir()) |
| 258 results_page = template.replace('%AbsolutePathToWebKitTrunk%', absolute_
path_to_trunk) | 258 results_page = template.replace('%AbsolutePathToWebKitTrunk%', absolute_
path_to_trunk) |
| 259 results_page = results_page.replace('%PeformanceTestsResultsJSON%', json
_output) | 259 results_page = results_page.replace('%PeformanceTestsResultsJSON%', json
_output) |
| 260 | 260 |
| 261 filesystem.write_text_file(self._results_page_path(), results_page) | 261 filesystem.write_text_file(self._results_page_path(), results_page) |
| 262 | 262 |
| 263 def _generate_results_dict(self, timestamp, description, platform, builder_n
ame, build_number): | 263 def _generate_results_dict(self, timestamp, description, platform, builder_n
ame, build_number): |
| 264 revisions = {} | 264 revisions = {} |
| 265 for (name, path) in self._port.repository_paths(): | 265 for (name, path) in self._port.repository_paths(): |
| 266 scm = SCMDetector(self._host.filesystem, self._host.executive).detec
t_scm_system(path) or self._host.scm() | 266 scm = SCMDetector(self._host.filesystem, self._host.executive).detec
t_scm_system(path) or self._host.scm() |
| 267 revision = scm.svn_revision(path) | 267 revision = scm.chromium_revision(path) |
| 268 revisions[name] = {'revision': revision, 'timestamp': scm.timestamp_
of_revision(path, revision)} | 268 revisions[name] = {'revision': revision, 'timestamp': scm.timestamp_
of_revision(path, revision)} |
| 269 | 269 |
| 270 meta_info = { | 270 meta_info = { |
| 271 'description': description, | 271 'description': description, |
| 272 'buildTime': self._datetime_in_ES5_compatible_iso_format(self._utc_t
imestamp), | 272 'buildTime': self._datetime_in_ES5_compatible_iso_format(self._utc_t
imestamp), |
| 273 'platform': platform, | 273 'platform': platform, |
| 274 'revisions': revisions, | 274 'revisions': revisions, |
| 275 'builderName': builder_name, | 275 'builderName': builder_name, |
| 276 'buildNumber': int(build_number) if build_number else None} | 276 'buildNumber': int(build_number) if build_number else None} |
| 277 | 277 |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 369 if metrics: | 369 if metrics: |
| 370 self._results.append((test, metrics)) | 370 self._results.append((test, metrics)) |
| 371 else: | 371 else: |
| 372 failures += 1 | 372 failures += 1 |
| 373 _log.error('FAILED') | 373 _log.error('FAILED') |
| 374 | 374 |
| 375 _log.info('Finished: %f s' % (time.time() - start_time)) | 375 _log.info('Finished: %f s' % (time.time() - start_time)) |
| 376 _log.info('') | 376 _log.info('') |
| 377 | 377 |
| 378 return failures | 378 return failures |
| OLD | NEW |