| OLD | NEW |
| 1 # Copyright (C) 2010 Google Inc. All rights reserved. | 1 # Copyright (C) 2010 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 15 matching lines...) Expand all Loading... |
| 26 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 26 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 27 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 27 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 28 | 28 |
| 29 import collections | 29 import collections |
| 30 import json | 30 import json |
| 31 import logging | 31 import logging |
| 32 import re | 32 import re |
| 33 import sys | 33 import sys |
| 34 import traceback | 34 import traceback |
| 35 | 35 |
| 36 from ..model.testfile import TestFile | 36 from model.testfile import TestFile |
| 37 | 37 |
| 38 JSON_RESULTS_FILE = "results.json" | 38 JSON_RESULTS_FILE = "results.json" |
| 39 JSON_RESULTS_FILE_SMALL = "results-small.json" | 39 JSON_RESULTS_FILE_SMALL = "results-small.json" |
| 40 JSON_RESULTS_PREFIX = "ADD_RESULTS(" | 40 JSON_RESULTS_PREFIX = "ADD_RESULTS(" |
| 41 JSON_RESULTS_SUFFIX = ");" | 41 JSON_RESULTS_SUFFIX = ");" |
| 42 | 42 |
| 43 JSON_RESULTS_MIN_TIME = 3 | 43 JSON_RESULTS_MIN_TIME = 3 |
| 44 JSON_RESULTS_HIERARCHICAL_VERSION = 4 | 44 JSON_RESULTS_HIERARCHICAL_VERSION = 4 |
| 45 JSON_RESULTS_MAX_BUILDS = 500 | 45 JSON_RESULTS_MAX_BUILDS = 500 |
| 46 JSON_RESULTS_MAX_BUILDS_SMALL = 100 | 46 JSON_RESULTS_MAX_BUILDS_SMALL = 100 |
| (...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 583 | 583 |
| 584 check_json_error_string = cls._check_json(builder, json_dict) | 584 check_json_error_string = cls._check_json(builder, json_dict) |
| 585 if check_json_error_string: | 585 if check_json_error_string: |
| 586 return None | 586 return None |
| 587 | 587 |
| 588 test_list_json = {} | 588 test_list_json = {} |
| 589 tests = json_dict[builder][TESTS_KEY] | 589 tests = json_dict[builder][TESTS_KEY] |
| 590 cls._delete_results_and_times(tests) | 590 cls._delete_results_and_times(tests) |
| 591 test_list_json[builder] = {TESTS_KEY: tests} | 591 test_list_json[builder] = {TESTS_KEY: tests} |
| 592 return cls._generate_file_data(test_list_json) | 592 return cls._generate_file_data(test_list_json) |
| OLD | NEW |