diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-20 02:18:09 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-20 02:18:09 +0300 |
commit | 6ed4ec3e0b1340f96b7c043ef51d1b33bbe85fde (patch) | |
tree | dc4d20fe6064752c0bd323187252c77e0a89144b /spec/frontend/header_search/init_spec.js | |
parent | 9868dae7fc0655bd7ce4a6887d4e6d487690eeed (diff) |
Add latest changes from gitlab-org/gitlab@15-4-stable-eev15.4.0-rc42
Diffstat (limited to 'spec/frontend/header_search/init_spec.js')
-rw-r--r-- | spec/frontend/header_search/init_spec.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/spec/frontend/header_search/init_spec.js b/spec/frontend/header_search/init_spec.js index 9515ca8c812..40c1843d461 100644 --- a/spec/frontend/header_search/init_spec.js +++ b/spec/frontend/header_search/init_spec.js @@ -24,10 +24,10 @@ describe('Header Search EventListener', () => { const addEventListenerSpy = jest.spyOn(searchInputBox, 'addEventListener'); initHeaderSearch(); - expect(addEventListenerSpy).toBeCalledTimes(2); + expect(addEventListenerSpy).toHaveBeenCalledTimes(2); }); - it('removes event listener ', async () => { + it('removes event listener', async () => { const searchInputBox = document?.querySelector('#search'); const removeEventListenerSpy = jest.spyOn(searchInputBox, 'removeEventListener'); jest.mock('~/header_search', () => ({ initHeaderSearchApp: jest.fn() })); @@ -39,7 +39,7 @@ describe('Header Search EventListener', () => { [cleanEventListeners], ); - expect(removeEventListenerSpy).toBeCalledTimes(2); + expect(removeEventListenerSpy).toHaveBeenCalledTimes(2); }); it('attaches new vue dropdown when feature flag is enabled', async () => { @@ -53,7 +53,7 @@ describe('Header Search EventListener', () => { () => {}, ); - expect(mockVueApp).toBeCalled(); + expect(mockVueApp).toHaveBeenCalled(); }); it('attaches old vue dropdown when feature flag is disabled', async () => { @@ -69,6 +69,6 @@ describe('Header Search EventListener', () => { () => {}, ); - expect(mockLegacyApp).toBeCalled(); + expect(mockLegacyApp).toHaveBeenCalled(); }); }); |