| Index: Tools/GardeningServer/model/test/ct-failures-tests.html
|
| diff --git a/Tools/GardeningServer/model/test/ct-failures-tests.html b/Tools/GardeningServer/model/test/ct-failures-tests.html
|
| index 925d5306ff7a22c9f29e3f05a494cb3498989d3b..4edcf5072185965e96366ad850e18a0c8f772306 100644
|
| --- a/Tools/GardeningServer/model/test/ct-failures-tests.html
|
| +++ b/Tools/GardeningServer/model/test/ct-failures-tests.html
|
| @@ -413,7 +413,7 @@ describe('ct-failures', function() {
|
| it('should filter out updates that are not alerts', function() {
|
| var analyzer = new CTFailures(new CTCommitList(undefined, []));
|
| analyzer.failures = {};
|
| - analyzer._processTrooperFailures(
|
| + analyzer._processTrooperFailures({},
|
| {'key_1': {'tree_1': {should_alert: true, should_appear: true},
|
| 'tree_2': {should_alert: false, should_appear: false}},
|
| 'key_2': {'tree_3': {should_alert: false, should_appear: false},
|
| @@ -425,6 +425,25 @@ describe('ct-failures', function() {
|
| });
|
| });
|
|
|
| + describe('processTrooperFailures', function() {
|
| + it('should list all failures with category builder and master', function() {
|
| + var emptyCommit = new CTCommitList(undefined, []);
|
| + var emptyGroupData = new CTStepFailureGroupData([], emptyCommit);
|
| + var group1 = new CTFailureGroup('', emptyGroupData, 'builder');
|
| + var group2 = new CTFailureGroup('', emptyGroupData, 'failedOnce');
|
| + var group3 = new CTFailureGroup('', emptyGroupData, 'master');
|
| +
|
| + var analyzer = new CTFailures(new CTCommitList(undefined, []));
|
| + analyzer.failures = {};
|
| + analyzer._processTrooperFailures(
|
| + {'tree_1': [group1], 'tree_2': [group2, group3]}, {});
|
| + analyzer.failures['trooper'].forEach(function(failure) {
|
| + assert(failure.category == 'builder' || failure.category == 'master');
|
| + });
|
| + assert(analyzer.failures['trooper'].length == 2);
|
| + });
|
| + });
|
| +
|
| describe('processFailuresForRangeGroup', function() {
|
| it('should use tree name from json', function() {
|
| var analyzer = new CTFailures(null);
|
|
|