Commit fe177f19 by Marcus Efraimsson

dashboard: fix search results tests #10083

parent 0029d965
...@@ -8,7 +8,7 @@ describe('SearchResultsCtrl', () => { ...@@ -8,7 +8,7 @@ describe('SearchResultsCtrl', () => {
let selectionChanged = false; let selectionChanged = false;
beforeEach(() => { beforeEach(() => {
ctrl = new SearchResultsCtrl(); ctrl = new SearchResultsCtrl({});
ctrl.onSelectionChanged = () => selectionChanged = true; ctrl.onSelectionChanged = () => selectionChanged = true;
ctrl.toggleSelection(item); ctrl.toggleSelection(item);
}); });
...@@ -27,7 +27,7 @@ describe('SearchResultsCtrl', () => { ...@@ -27,7 +27,7 @@ describe('SearchResultsCtrl', () => {
let selectionChanged = false; let selectionChanged = false;
beforeEach(() => { beforeEach(() => {
ctrl = new SearchResultsCtrl(); ctrl = new SearchResultsCtrl({});
ctrl.onSelectionChanged = () => selectionChanged = true; ctrl.onSelectionChanged = () => selectionChanged = true;
ctrl.toggleSelection(item); ctrl.toggleSelection(item);
}); });
...@@ -45,7 +45,7 @@ describe('SearchResultsCtrl', () => { ...@@ -45,7 +45,7 @@ describe('SearchResultsCtrl', () => {
let selectedTag = null; let selectedTag = null;
beforeEach(() => { beforeEach(() => {
ctrl = new SearchResultsCtrl(); ctrl = new SearchResultsCtrl({});
ctrl.onTagSelected = (tag) => selectedTag = tag; ctrl.onTagSelected = (tag) => selectedTag = tag;
ctrl.selectTag('tag-test'); ctrl.selectTag('tag-test');
}); });
...@@ -64,7 +64,7 @@ describe('SearchResultsCtrl', () => { ...@@ -64,7 +64,7 @@ describe('SearchResultsCtrl', () => {
}; };
beforeEach(() => { beforeEach(() => {
ctrl = new SearchResultsCtrl(); ctrl = new SearchResultsCtrl({});
ctrl.toggleFolderExpand(folder); ctrl.toggleFolderExpand(folder);
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment