Commit 8e6d4aad authored by Martin Wortschack's avatar Martin Wortschack

Merge branch 'xanf-remove-localVue-121741' into 'master'

Remove incorrect localVue usage in spec/frontend/diffs

Closes #121741

See merge request gitlab-org/gitlab!22581
parents c036d7a2 3f777709
import { shallowMount, createLocalVue } from '@vue/test-utils'; import { shallowMount } from '@vue/test-utils';
import DiffGutterAvatars from '~/diffs/components/diff_gutter_avatars.vue'; import DiffGutterAvatars from '~/diffs/components/diff_gutter_avatars.vue';
import discussionsMockData from '../mock_data/diff_discussions'; import discussionsMockData from '../mock_data/diff_discussions';
const localVue = createLocalVue();
const getDiscussionsMockData = () => [Object.assign({}, discussionsMockData)]; const getDiscussionsMockData = () => [Object.assign({}, discussionsMockData)];
describe('DiffGutterAvatars', () => { describe('DiffGutterAvatars', () => {
...@@ -14,7 +13,6 @@ describe('DiffGutterAvatars', () => { ...@@ -14,7 +13,6 @@ describe('DiffGutterAvatars', () => {
const createComponent = (props = {}) => { const createComponent = (props = {}) => {
wrapper = shallowMount(DiffGutterAvatars, { wrapper = shallowMount(DiffGutterAvatars, {
localVue,
propsData: { propsData: {
...props, ...props,
}, },
......
import { shallowMount, createLocalVue } from '@vue/test-utils'; import { shallowMount } from '@vue/test-utils';
import EditButton from '~/diffs/components/edit_button.vue'; import EditButton from '~/diffs/components/edit_button.vue';
const localVue = createLocalVue();
const editPath = 'test-path'; const editPath = 'test-path';
describe('EditButton', () => { describe('EditButton', () => {
...@@ -9,7 +8,6 @@ describe('EditButton', () => { ...@@ -9,7 +8,6 @@ describe('EditButton', () => {
const createComponent = (props = {}) => { const createComponent = (props = {}) => {
wrapper = shallowMount(EditButton, { wrapper = shallowMount(EditButton, {
localVue,
propsData: { ...props }, propsData: { ...props },
sync: false, sync: false,
attachToDocument: true, attachToDocument: true,
......
import { shallowMount, createLocalVue } from '@vue/test-utils'; import { shallowMount } from '@vue/test-utils';
import HiddenFilesWarning from '~/diffs/components/hidden_files_warning.vue'; import HiddenFilesWarning from '~/diffs/components/hidden_files_warning.vue';
const localVue = createLocalVue();
const propsData = { const propsData = {
total: '10', total: '10',
visible: 5, visible: 5,
...@@ -14,7 +13,6 @@ describe('HiddenFilesWarning', () => { ...@@ -14,7 +13,6 @@ describe('HiddenFilesWarning', () => {
const createComponent = () => { const createComponent = () => {
wrapper = shallowMount(HiddenFilesWarning, { wrapper = shallowMount(HiddenFilesWarning, {
localVue,
sync: false, sync: false,
propsData, propsData,
}); });
......
...@@ -13,7 +13,7 @@ describe('Diff no changes empty state', () => { ...@@ -13,7 +13,7 @@ describe('Diff no changes empty state', () => {
const store = createStore(); const store = createStore();
extendStore(store); extendStore(store);
vm = shallowMount(localVue.extend(NoChanges), { vm = shallowMount(NoChanges, {
localVue, localVue,
store, store,
propsData: { propsData: {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment