summaryrefslogtreecommitdiff
path: root/spec/frontend/batch_comments
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-06-24 00:08:09 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2022-06-24 00:08:09 +0000
commita9720e77c10b98e427e54384b507683d4c4bfbbd (patch)
tree35448d685e5e29cad7563619f8c0de3c411453f7 /spec/frontend/batch_comments
parent145fb28542af4441ee8dc5752f9879ec1c1de15d (diff)
downloadgitlab-ce-a9720e77c10b98e427e54384b507683d4c4bfbbd.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/batch_comments')
-rw-r--r--spec/frontend/batch_comments/stores/modules/batch_comments/actions_spec.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/spec/frontend/batch_comments/stores/modules/batch_comments/actions_spec.js b/spec/frontend/batch_comments/stores/modules/batch_comments/actions_spec.js
index 172b510645d..9f50b12bac2 100644
--- a/spec/frontend/batch_comments/stores/modules/batch_comments/actions_spec.js
+++ b/spec/frontend/batch_comments/stores/modules/batch_comments/actions_spec.js
@@ -298,14 +298,18 @@ describe('Batch comments store actions', () => {
const draft = {
discussion_id: '1',
id: '2',
+ file_path: 'lib/example.js',
};
actions.scrollToDraft({ dispatch, rootGetters }, draft);
- expect(dispatch.mock.calls[0]).toEqual([
- 'expandDiscussion',
- { discussionId: '1' },
- { root: true },
+ expect(dispatch.mock.calls).toEqual([
+ [
+ 'diffs/setFileCollapsedAutomatically',
+ { filePath: draft.file_path, collapsed: false },
+ { root: true },
+ ],
+ ['expandDiscussion', { discussionId: '1' }, { root: true }],
]);
expect(window.mrTabs.tabShown).toHaveBeenCalledWith('diffs');