-
Notifications
You must be signed in to change notification settings - Fork 212
issue-5063 changes #5083
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: unstable
Are you sure you want to change the base?
issue-5063 changes #5083
Changes from all commits
d1e6068
130b5b9
12c0855
ce1b772
cb52302
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -70,4 +70,13 @@ describe('account tab', () => { | |
await wrapper.vm.$nextTick(); | ||
expect(wrapper.vm.showExportDataNotice).toBe(true); | ||
}); | ||
|
||
it('export data failure', async () => { | ||
const exportData = jest.spyOn(wrapper.vm, 'exportData'); | ||
exportData.mockImplementation(() => Promise.reject('error')); | ||
await wrapper.find('[data-test="export-link"]').trigger('click'); | ||
expect(exportData).toHaveBeenCalled(); | ||
expect(wrapper.vm.showExportDataNotice).toBe(false); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Testing whether a modal is displayed via checking on I realize this is a pattern that is present in other tests around this dialog. If you'd like to fix them too, that'd be welcome, but it's not required as it was pre-existing. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure, will update There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks @yeshwanth235, just mention me in the PR if you had any questions or as soon as all feedback is resolved. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hi @MisRob Can you please elaborate more on other tests around this Dialog. I am not getting it |
||
expect(wrapper.vm.$store.dispatch).toHaveBeenCalledWith('showSnackbar', { text: wrapper.vm.$tr('exportFailed') }); | ||
}); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for following the guidance and updating these!