Log Message
Be more aggressive about deleting unnecessary results from the test-results-server json files https://bugs.webkit.org/show_bug.cgi?id=76086
Reviewed by Tony Chang. Remove any tests that only contain skip/pass/nodata values whose runtime is less than 5 seconds. * TestResultServer/model/jsonresults.py: (JsonResults._normalize_results_json): * TestResultServer/model/jsonresults_unittest.py: (JsonResultsTest.test_merge_remove_test): (JsonResultsTest.test_merge_keep_test_with_all_pass_but_slow_time):
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (104730 => 104731)
--- trunk/Tools/ChangeLog 2012-01-11 19:57:12 UTC (rev 104730)
+++ trunk/Tools/ChangeLog 2012-01-11 20:01:24 UTC (rev 104731)
@@ -1,3 +1,19 @@
+2012-01-11 Ojan Vafai <[email protected]>
+
+ Be more aggressive about deleting unnecessary results from the test-results-server json files
+ https://bugs.webkit.org/show_bug.cgi?id=76086
+
+ Reviewed by Tony Chang.
+
+ Remove any tests that only contain skip/pass/nodata values whose runtime
+ is less than 5 seconds.
+
+ * TestResultServer/model/jsonresults.py:
+ (JsonResults._normalize_results_json):
+ * TestResultServer/model/jsonresults_unittest.py:
+ (JsonResultsTest.test_merge_remove_test):
+ (JsonResultsTest.test_merge_keep_test_with_all_pass_but_slow_time):
+
2012-01-11 Ryosuke Niwa <[email protected]>
last-green-revision should give us per-bot information
Modified: trunk/Tools/TestResultServer/model/jsonresults.py (104730 => 104731)
--- trunk/Tools/TestResultServer/model/jsonresults.py 2012-01-11 19:57:12 UTC (rev 104730)
+++ trunk/Tools/TestResultServer/model/jsonresults.py 2012-01-11 20:01:24 UTC (rev 104731)
@@ -44,8 +44,9 @@
JSON_RESULTS_RESULTS = "results"
JSON_RESULTS_TIMES = "times"
JSON_RESULTS_PASS = "P"
+JSON_RESULTS_SKIP = "X"
JSON_RESULTS_NO_DATA = "N"
-JSON_RESULTS_MIN_TIME = 1
+JSON_RESULTS_MIN_TIME = 5
JSON_RESULTS_HIERARCHICAL_VERSION = 4
JSON_RESULTS_MAX_BUILDS = 750
JSON_RESULTS_MAX_BUILDS_SMALL = 200
@@ -208,13 +209,17 @@
aggregated_test[JSON_RESULTS_RESULTS] = cls._remove_items_over_max_number_of_builds(aggregated_test[JSON_RESULTS_RESULTS], num_runs)
aggregated_test[JSON_RESULTS_TIMES] = cls._remove_items_over_max_number_of_builds(aggregated_test[JSON_RESULTS_TIMES], num_runs)
- is_all_pass = cls._is_results_all_of_type(aggregated_test[JSON_RESULTS_RESULTS], JSON_RESULTS_PASS)
- is_all_no_data = cls._is_results_all_of_type(aggregated_test[JSON_RESULTS_RESULTS], JSON_RESULTS_NO_DATA)
+ deletable_types = set((JSON_RESULTS_PASS, JSON_RESULTS_NO_DATA, JSON_RESULTS_SKIP))
+ for result in aggregated_test[JSON_RESULTS_RESULTS]:
+ if result[1] not in deletable_types:
+ return
- max_time = max([time[1] for time in aggregated_test[JSON_RESULTS_TIMES]])
- if (is_all_no_data or (is_all_pass and max_time < JSON_RESULTS_MIN_TIME)):
- del aggregated_json[test_name]
+ for time in aggregated_test[JSON_RESULTS_TIMES]:
+ if time[1] >= JSON_RESULTS_MIN_TIME:
+ return
+ del aggregated_json[test_name]
+
@classmethod
def _remove_items_over_max_number_of_builds(cls, encoded_list, num_runs):
num_builds = 0
Modified: trunk/Tools/TestResultServer/model/jsonresults_unittest.py (104730 => 104731)
--- trunk/Tools/TestResultServer/model/jsonresults_unittest.py 2012-01-11 19:57:12 UTC (rev 104730)
+++ trunk/Tools/TestResultServer/model/jsonresults_unittest.py 2012-01-11 20:01:24 UTC (rev 104731)
@@ -384,42 +384,20 @@
"results": [[7,"F"]],
"times": [[7,0]]}}})
- def test_merge_remove_test_with_no_data(self):
- # Remove test where there is no data in all runs.
+ def test_merge_remove_test(self):
self._test_merge(
# Aggregated results
{"builds": ["2", "1"],
"tests": {"001.html": {
- "results": [[200,"N"]],
- "times": [[200,0]]},
- "002.html": {
- "results": [[10,"F"]],
- "times": [[10,0]]}}},
- # Incremental results
- {"builds": ["3"],
- "tests": {"001.html": {
- "results": [[1,"N"]],
- "times": [[1,0]]},
- "002.html": {
- "results": [[1,"P"]],
- "times": [[1,0]]}}},
- # Expected results
- {"builds": ["3", "2", "1"],
- "tests": {"002.html": {
- "results": [[1,"P"],[10,"F"]],
- "times": [[11,0]]}}})
-
- def test_merge_remove_test_with_all_pass(self):
- # Remove test where all run pass and max running time < 1 seconds
- self._test_merge(
- # Aggregated results
- {"builds": ["2", "1"],
- "tests": {"001.html": {
"results": [[200,"P"]],
"times": [[200,0]]},
"002.html": {
"results": [[10,"F"]],
- "times": [[10,0]]}}},
+ "times": [[10,0]]},
+ "003.html": {
+ "results": [[190, 'X'], [9, 'N'], [1,"F"]],
+ "times": [[200,0]]},
+ }},
# Incremental results
{"builds": ["3"],
"tests": {"001.html": {
@@ -427,21 +405,26 @@
"times": [[1,0]]},
"002.html": {
"results": [[1,"P"]],
- "times": [[1,0]]}}},
+ "times": [[1,0]]},
+ "003.html": {
+ "results": [[1,"P"]],
+ "times": [[1,0]]},
+ }},
# Expected results
{"builds": ["3", "2", "1"],
"tests": {"002.html": {
"results": [[1,"P"],[10,"F"]],
- "times": [[11,0]]}}})
+ "times": [[11,0]]}}},
+ max_builds=200)
def test_merge_keep_test_with_all_pass_but_slow_time(self):
- # Do not remove test where all run pass but max running time >= 1 seconds
+ # Do not remove test where all run pass but max running time >= 5 seconds
self._test_merge(
# Aggregated results
{"builds": ["2", "1"],
"tests": {"001.html": {
"results": [[200,"P"]],
- "times": [[200,0]]},
+ "times": [[200,5]]},
"002.html": {
"results": [[10,"F"]],
"times": [[10,0]]}}},
@@ -457,7 +440,7 @@
{"builds": ["3", "2", "1"],
"tests": {"001.html": {
"results": [[201,"P"]],
- "times": [[1,1],[200,0]]},
+ "times": [[1,1],[200,5]]},
"002.html": {
"results": [[1,"P"],[10,"F"]],
"times": [[11,0]]}}})
_______________________________________________ webkit-changes mailing list [email protected] http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes
