diff options
Diffstat (limited to 'spec/frontend/profile/account')
-rw-r--r-- | spec/frontend/profile/account/components/delete_account_modal_spec.js | 2 | ||||
-rw-r--r-- | spec/frontend/profile/account/components/update_username_spec.js | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/spec/frontend/profile/account/components/delete_account_modal_spec.js b/spec/frontend/profile/account/components/delete_account_modal_spec.js index ad62d84c43c..e4a316e1ee7 100644 --- a/spec/frontend/profile/account/components/delete_account_modal_spec.js +++ b/spec/frontend/profile/account/components/delete_account_modal_spec.js @@ -53,7 +53,7 @@ describe('DeleteAccountModal component', () => { input: vm.$el.querySelector(`[name="${confirmation}"]`), }; }; - const findModal = () => wrapper.find(GlModalStub); + const findModal = () => wrapper.findComponent(GlModalStub); describe('with password confirmation', () => { beforeEach(async () => { diff --git a/spec/frontend/profile/account/components/update_username_spec.js b/spec/frontend/profile/account/components/update_username_spec.js index 0e56bccf27e..e331eed1863 100644 --- a/spec/frontend/profile/account/components/update_username_spec.js +++ b/spec/frontend/profile/account/components/update_username_spec.js @@ -44,7 +44,7 @@ describe('UpdateUsername component', () => { }); const findElements = () => { - const modal = wrapper.find(GlModal); + const modal = wrapper.findComponent(GlModal); return { modal, @@ -149,7 +149,7 @@ describe('UpdateUsername component', () => { await expect(wrapper.vm.onConfirm()).rejects.toThrow(); - expect(createFlash).toBeCalledWith({ + expect(createFlash).toHaveBeenCalledWith({ message: 'Invalid username', }); }); @@ -161,7 +161,7 @@ describe('UpdateUsername component', () => { await expect(wrapper.vm.onConfirm()).rejects.toThrow(); - expect(createFlash).toBeCalledWith({ + expect(createFlash).toHaveBeenCalledWith({ message: 'An error occurred while updating your username, please try again.', }); }); |