diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 12:45:46 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-02-18 12:45:46 +0300 |
commit | a7b3560714b4d9cc4ab32dffcd1f74a284b93580 (patch) | |
tree | 7452bd5c3545c2fa67a28aa013835fb4fa071baf /spec/frontend/persistent_user_callout_spec.js | |
parent | ee9173579ae56a3dbfe5afe9f9410c65bb327ca7 (diff) |
Add latest changes from gitlab-org/gitlab@14-8-stable-eev14.8.0-rc42
Diffstat (limited to 'spec/frontend/persistent_user_callout_spec.js')
-rw-r--r-- | spec/frontend/persistent_user_callout_spec.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/spec/frontend/persistent_user_callout_spec.js b/spec/frontend/persistent_user_callout_spec.js index 1db255106ed..4633602de26 100644 --- a/spec/frontend/persistent_user_callout_spec.js +++ b/spec/frontend/persistent_user_callout_spec.js @@ -10,6 +10,7 @@ jest.mock('~/flash'); describe('PersistentUserCallout', () => { const dismissEndpoint = '/dismiss'; const featureName = 'feature'; + const groupId = '5'; function createFixture() { const fixture = document.createElement('div'); @@ -18,6 +19,7 @@ describe('PersistentUserCallout', () => { class="container" data-dismiss-endpoint="${dismissEndpoint}" data-feature-id="${featureName}" + data-group-id="${groupId}" > <button type="button" class="js-close"></button> </div> @@ -86,7 +88,9 @@ describe('PersistentUserCallout', () => { return waitForPromises().then(() => { expect(persistentUserCallout.container.remove).toHaveBeenCalled(); - expect(mockAxios.history.post[0].data).toBe(JSON.stringify({ feature_name: featureName })); + expect(mockAxios.history.post[0].data).toBe( + JSON.stringify({ feature_name: featureName, group_id: groupId }), + ); }); }); @@ -191,8 +195,8 @@ describe('PersistentUserCallout', () => { return waitForPromises().then(() => { expect(window.location.assign).toBeCalledWith(href); - expect(mockAxios.history.post[0].data).toBe(JSON.stringify({ feature_name: featureName })); expect(persistentUserCallout.container.remove).not.toHaveBeenCalled(); + expect(mockAxios.history.post[0].data).toBe(JSON.stringify({ feature_name: featureName })); }); }); |