diff options
Diffstat (limited to 'spec/frontend/diffs/components')
4 files changed, 16 insertions, 4 deletions
diff --git a/spec/frontend/diffs/components/diff_file_spec.js b/spec/frontend/diffs/components/diff_file_spec.js index d0ba71fce47..71e975f2409 100644 --- a/spec/frontend/diffs/components/diff_file_spec.js +++ b/spec/frontend/diffs/components/diff_file_spec.js @@ -1,5 +1,5 @@ import Vue from 'vue'; -import { createStore } from 'ee_else_ce/mr_notes/stores'; +import { createStore } from '~/mr_notes/stores'; import { createComponentWithStore } from 'helpers/vue_mount_component_helper'; import { mockTracking, triggerEvent } from 'helpers/tracking_helper'; import DiffFileComponent from '~/diffs/components/diff_file.vue'; diff --git a/spec/frontend/diffs/components/diff_line_note_form_spec.js b/spec/frontend/diffs/components/diff_line_note_form_spec.js index 3e0acd0dace..623df8bd55e 100644 --- a/spec/frontend/diffs/components/diff_line_note_form_spec.js +++ b/spec/frontend/diffs/components/diff_line_note_form_spec.js @@ -77,12 +77,24 @@ describe('DiffLineNoteForm', () => { .spyOn(wrapper.vm, 'saveDiffDiscussion') .mockReturnValue(Promise.resolve()); + const lineRange = { + start_line_code: wrapper.vm.commentLineStart.lineCode, + start_line_type: wrapper.vm.commentLineStart.type, + end_line_code: wrapper.vm.line.line_code, + end_line_type: wrapper.vm.line.type, + }; + + const formData = { + ...wrapper.vm.formData, + lineRange, + }; + wrapper.vm .handleSaveNote('note body') .then(() => { expect(saveDiffDiscussionSpy).toHaveBeenCalledWith({ note: 'note body', - formData: wrapper.vm.formData, + formData, }); }) .then(done) diff --git a/spec/frontend/diffs/components/inline_diff_view_spec.js b/spec/frontend/diffs/components/inline_diff_view_spec.js index 9b0cf6a84d9..eeef8e5a7b0 100644 --- a/spec/frontend/diffs/components/inline_diff_view_spec.js +++ b/spec/frontend/diffs/components/inline_diff_view_spec.js @@ -1,6 +1,6 @@ import Vue from 'vue'; import '~/behaviors/markdown/render_gfm'; -import { createStore } from 'ee_else_ce/mr_notes/stores'; +import { createStore } from '~/mr_notes/stores'; import { createComponentWithStore } from 'helpers/vue_mount_component_helper'; import InlineDiffView from '~/diffs/components/inline_diff_view.vue'; import diffFileMockData from '../mock_data/diff_file'; diff --git a/spec/frontend/diffs/components/parallel_diff_view_spec.js b/spec/frontend/diffs/components/parallel_diff_view_spec.js index 03cf1b72b62..30231f0ba71 100644 --- a/spec/frontend/diffs/components/parallel_diff_view_spec.js +++ b/spec/frontend/diffs/components/parallel_diff_view_spec.js @@ -1,5 +1,5 @@ import Vue from 'vue'; -import { createStore } from 'ee_else_ce/mr_notes/stores'; +import { createStore } from '~/mr_notes/stores'; import { createComponentWithStore } from 'helpers/vue_mount_component_helper'; import ParallelDiffView from '~/diffs/components/parallel_diff_view.vue'; import * as constants from '~/diffs/constants'; |