Commit f8f4fd30 authored by Simon Knox's avatar Simon Knox

Fix flaky spec caused by missing stub return value

vm.loadList() is called in the mounted method of
board_list_selector, so when the component is mounted in
beforeEach, then loadList gets called and assignees list
_is_ empty. There is probably something worse going on
underneath here but this seems like an easy safe workaround
parent e5f8b338
...@@ -58,7 +58,7 @@ describe('BoardListSelector', () => { ...@@ -58,7 +58,7 @@ describe('BoardListSelector', () => {
}); });
it('does not call axios.get when store.state.assignees is not empty', done => { it('does not call axios.get when store.state.assignees is not empty', done => {
spyOn(axios, 'get'); spyOn(axios, 'get').and.returnValue(Promise.resolve());
boardsStore.state.assignees = mockAssigneesList; boardsStore.state.assignees = mockAssigneesList;
vm.loadList() vm.loadList()
......
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