[Search] Repurposed checkAll test. #1117

Changed test to ensure checkAll and it's appropriate filter string are 
set whenever checkAll is changed.
Removed redundant line checking for a filter string of 'NONE' as this 
is no longer a possibility.
This commit is contained in:
Kevin Van Kessel 2016-08-28 12:01:42 -07:00 committed by GitHub
parent 702ebbd557
commit 6cbdaa442b

View File

@ -76,13 +76,15 @@ define(
expect(mockScope.ngModel.filtersString).not.toEqual('');
});
it("changing checkAll status updates the filter string", function () {
it("changing checkAll status sets checkAll to true", function () {
controller.checkAll();
expect(mockScope.ngModel.checkAll).toEqual(true);
expect(mockScope.ngModel.filtersString).toEqual('');
mockScope.ngModel.checkAll = false;
controller.checkAll();
expect(mockScope.ngModel.checkAll).toEqual(true);
expect(mockScope.ngModel.filtersString).toEqual('');
});
@ -117,7 +119,6 @@ define(
controller.updateOptions();
expect(mockScope.ngModel.filtersString).not.toEqual('NONE');
expect(mockScope.ngModel.filtersString).not.toEqual('');
});
});