diff options
Diffstat (limited to 'spec/frontend/jira_connect/store/mutations_spec.js')
-rw-r--r-- | spec/frontend/jira_connect/store/mutations_spec.js | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/spec/frontend/jira_connect/store/mutations_spec.js b/spec/frontend/jira_connect/store/mutations_spec.js index d1f9d22b3de..584b17b36f7 100644 --- a/spec/frontend/jira_connect/store/mutations_spec.js +++ b/spec/frontend/jira_connect/store/mutations_spec.js @@ -8,11 +8,21 @@ describe('JiraConnect store mutations', () => { localState = state(); }); - describe('SET_ERROR_MESSAGE', () => { - it('sets error message', () => { - mutations.SET_ERROR_MESSAGE(localState, 'test error'); + describe('SET_ALERT', () => { + it('sets alert state', () => { + mutations.SET_ALERT(localState, { + message: 'test error', + variant: 'danger', + title: 'test title', + linkUrl: 'linkUrl', + }); - expect(localState.errorMessage).toBe('test error'); + expect(localState.alert).toMatchObject({ + message: 'test error', + variant: 'danger', + title: 'test title', + linkUrl: 'linkUrl', + }); }); }); }); |