| OLD | NEW |
| 1 # Copyright (C) 2010 Google Inc. All rights reserved. | 1 # Copyright (C) 2010 Google Inc. All rights reserved. |
| 2 # Copyright (C) 2010 Gabor Rapcsanyi (rgabor@inf.u-szeged.hu), University of Sze
ged | 2 # Copyright (C) 2010 Gabor Rapcsanyi (rgabor@inf.u-szeged.hu), University of Sze
ged |
| 3 # | 3 # |
| 4 # Redistribution and use in source and binary forms, with or without | 4 # Redistribution and use in source and binary forms, with or without |
| 5 # modification, are permitted provided that the following conditions are | 5 # modification, are permitted provided that the following conditions are |
| 6 # met: | 6 # met: |
| 7 # | 7 # |
| 8 # * Redistributions of source code must retain the above copyright | 8 # * Redistributions of source code must retain the above copyright |
| 9 # notice, this list of conditions and the following disclaimer. | 9 # notice, this list of conditions and the following disclaimer. |
| 10 # * Redistributions in binary form must reproduce the above | 10 # * Redistributions in binary form must reproduce the above |
| (...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 353 | 353 |
| 354 test_inputs = [] | 354 test_inputs = [] |
| 355 for _ in xrange(iterations): | 355 for _ in xrange(iterations): |
| 356 for test in tests_to_run: | 356 for test in tests_to_run: |
| 357 for _ in xrange(repeat_each): | 357 for _ in xrange(repeat_each): |
| 358 test_inputs.append(self._test_input_for_file(test)) | 358 test_inputs.append(self._test_input_for_file(test)) |
| 359 return self._runner.run_tests(self._expectations, test_inputs, | 359 return self._runner.run_tests(self._expectations, test_inputs, |
| 360 tests_to_skip, num_workers, retry_attempt) | 360 tests_to_skip, num_workers, retry_attempt) |
| 361 | 361 |
| 362 def _start_servers(self, tests_to_run): | 362 def _start_servers(self, tests_to_run): |
| 363 if self._port.is_wptserve_enabled() and any(self._port.is_wptserve_test(
test) for test in tests_to_run): | 363 if any(self._port.is_wptserve_test(test) for test in tests_to_run): |
| 364 self._printer.write_update('Starting WPTServe ...') | 364 self._printer.write_update('Starting WPTServe ...') |
| 365 self._port.start_wptserve() | 365 self._port.start_wptserve() |
| 366 self._wptserve_started = True | 366 self._wptserve_started = True |
| 367 | 367 |
| 368 if self._port.requires_http_server() or any((self._is_http_test(test) or
self._is_inspector_test(test)) | 368 if self._port.requires_http_server() or any((self._is_http_test(test) or
self._is_inspector_test(test)) |
| 369 for test in tests_to_run): | 369 for test in tests_to_run): |
| 370 self._printer.write_update('Starting HTTP server ...') | 370 self._printer.write_update('Starting HTTP server ...') |
| 371 self._port.start_http_server(additional_dirs={}, number_of_drivers=s
elf._options.max_locked_shards) | 371 self._port.start_http_server(additional_dirs={}, number_of_drivers=s
elf._options.max_locked_shards) |
| 372 self._http_server_started = True | 372 self._http_server_started = True |
| 373 | 373 |
| (...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 538 | 538 |
| 539 stats = {} | 539 stats = {} |
| 540 for result in initial_results.results_by_name.values(): | 540 for result in initial_results.results_by_name.values(): |
| 541 if result.type != test_expectations.SKIP: | 541 if result.type != test_expectations.SKIP: |
| 542 stats[result.test_name] = {'results': (_worker_number(result.wor
ker_name), result.test_number, result.pid, int( | 542 stats[result.test_name] = {'results': (_worker_number(result.wor
ker_name), result.test_number, result.pid, int( |
| 543 result.test_run_time * 1000), int(result.total_run_time * 10
00))} | 543 result.test_run_time * 1000), int(result.total_run_time * 10
00))} |
| 544 stats_trie = {} | 544 stats_trie = {} |
| 545 for name, value in stats.iteritems(): | 545 for name, value in stats.iteritems(): |
| 546 json_results_generator.add_path_to_trie(name, value, stats_trie) | 546 json_results_generator.add_path_to_trie(name, value, stats_trie) |
| 547 return stats_trie | 547 return stats_trie |
| OLD | NEW |