diff options
Diffstat (limited to 'spec/frontend/sidebar')
-rw-r--r-- | spec/frontend/sidebar/confidential_issue_sidebar_spec.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/spec/frontend/sidebar/confidential_issue_sidebar_spec.js b/spec/frontend/sidebar/confidential_issue_sidebar_spec.js index e7a64ec5ed9..fe7c3aadeeb 100644 --- a/spec/frontend/sidebar/confidential_issue_sidebar_spec.js +++ b/spec/frontend/sidebar/confidential_issue_sidebar_spec.js @@ -6,11 +6,14 @@ import SidebarService from '~/sidebar/services/sidebar_service'; import createFlash from '~/flash'; import RecaptchaModal from '~/vue_shared/components/recaptcha_modal.vue'; import createStore from '~/notes/stores'; +import { useMockLocationHelper } from 'helpers/mock_window_location_helper'; jest.mock('~/flash'); jest.mock('~/sidebar/services/sidebar_service'); describe('Confidential Issue Sidebar Block', () => { + useMockLocationHelper(); + let wrapper; const findRecaptchaModal = () => wrapper.find(RecaptchaModal); @@ -43,10 +46,6 @@ describe('Confidential Issue Sidebar Block', () => { }); }; - beforeEach(() => { - jest.spyOn(window.location, 'reload').mockImplementation(); - }); - afterEach(() => { wrapper.destroy(); }); |