diff options
author | Mike Greiling <mike@pixelcog.com> | 2018-04-14 06:49:11 +0300 |
---|---|---|
committer | Mike Greiling <mike@pixelcog.com> | 2018-04-23 08:54:20 +0300 |
commit | 704e86613459fccfbab882de69f73c54372be611 (patch) | |
tree | 8117687740f6c7dcb0cf6da0bfa4d0fc6ae69825 /spec/javascripts/todos_spec.js | |
parent | 1f1af49a41be0072b7a5d37d47b470bea4daf222 (diff) |
fix more instances of "import *" with spyOnDependency
Diffstat (limited to 'spec/javascripts/todos_spec.js')
-rw-r--r-- | spec/javascripts/todos_spec.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/spec/javascripts/todos_spec.js b/spec/javascripts/todos_spec.js index 898bbb3819b..e74f4bdef7e 100644 --- a/spec/javascripts/todos_spec.js +++ b/spec/javascripts/todos_spec.js @@ -1,5 +1,4 @@ import $ from 'jquery'; -import * as urlUtils from '~/lib/utils/url_utility'; import Todos from '~/pages/dashboard/todos/index/todos'; import '~/lib/utils/common_utils'; @@ -18,7 +17,7 @@ describe('Todos', () => { it('opens the todo url', (done) => { const todoLink = todoItem.dataset.url; - spyOn(urlUtils, 'visitUrl').and.callFake((url) => { + spyOnDependency(Todos, 'visitUrl').and.callFake((url) => { expect(url).toEqual(todoLink); done(); }); @@ -33,7 +32,7 @@ describe('Todos', () => { beforeEach(() => { metakeyEvent = $.Event('click', { keyCode: 91, ctrlKey: true }); - visitUrlSpy = spyOn(urlUtils, 'visitUrl').and.callFake(() => {}); + visitUrlSpy = spyOnDependency(Todos, 'visitUrl').and.callFake(() => {}); windowOpenSpy = spyOn(window, 'open').and.callFake(() => {}); }); |