Rename vue_component_helper to text_helper
**Why?** This file only contains a few text based helper functions. It has nothing to do with Vue or Vue components.
This commit is contained in:
parent
9afe8d3bcd
commit
878e69299b
21 changed files with 19 additions and 19 deletions
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import { TEST_HOST } from 'spec/test_constants';
|
||||
import mountComponent from 'spec/helpers/vue_mount_component_helper';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
import { getTimeago } from '~/lib/utils/datetime_utility';
|
||||
import CommitItem from '~/diffs/components/commit_item.vue';
|
||||
import getDiffWithCommit from '../mock_data/diff_with_commit';
|
||||
|
|
|
@ -3,7 +3,7 @@ import MockAdapter from 'axios-mock-adapter';
|
|||
import axios from '~/lib/utils/axios_utils';
|
||||
import environmentsFolderViewComponent from '~/environments/folder/environments_folder_view.vue';
|
||||
import mountComponent from 'spec/helpers/vue_mount_component_helper';
|
||||
import { removeBreakLine, removeWhitespace } from 'spec/helpers/vue_component_helper';
|
||||
import { removeBreakLine, removeWhitespace } from 'spec/helpers/text_helper';
|
||||
import { environmentsList } from '../mock_data';
|
||||
|
||||
describe('Environments Folder View', () => {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import frequentItemsListItemComponent from '~/frequent_items/components/frequent_items_list_item.vue';
|
||||
import { shallowMount } from '@vue/test-utils';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
import { mockProject } from '../mock_data'; // can also use 'mockGroup', but not useful to test here
|
||||
|
||||
const createComponent = () => {
|
||||
|
|
|
@ -3,7 +3,7 @@ import store from '~/ide/stores';
|
|||
import listCollapsed from '~/ide/components/commit_sidebar/list_collapsed.vue';
|
||||
import { createComponentWithStore } from 'spec/helpers/vue_mount_component_helper';
|
||||
import { file } from '../../helpers';
|
||||
import { removeWhitespace } from '../../../helpers/vue_component_helper';
|
||||
import { removeWhitespace } from '../../../helpers/text_helper';
|
||||
|
||||
describe('Multi-file editor commit sidebar list collapsed', () => {
|
||||
let vm;
|
||||
|
|
|
@ -2,7 +2,7 @@ import Vue from 'vue';
|
|||
import IdeReview from '~/ide/components/ide_review.vue';
|
||||
import store from '~/ide/stores';
|
||||
import { createComponentWithStore } from '../../helpers/vue_mount_component_helper';
|
||||
import { trimText } from '../../helpers/vue_component_helper';
|
||||
import { trimText } from '../../helpers/text_helper';
|
||||
import { resetStore, file } from '../helpers';
|
||||
import { projectData } from '../mock_data';
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import NavDropdownButton from '~/ide/components/nav_dropdown_button.vue';
|
||||
import store from '~/ide/stores';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
import { mountComponentWithStore } from 'spec/helpers/vue_mount_component_helper';
|
||||
import { resetStore } from '../helpers';
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@ import Vue from 'vue';
|
|||
import { getTimeago } from '~/lib/utils/datetime_utility';
|
||||
import component from '~/jobs/components/artifacts_block.vue';
|
||||
import mountComponent from '../../helpers/vue_mount_component_helper';
|
||||
import { trimText } from '../../helpers/vue_component_helper';
|
||||
import { trimText } from '../../helpers/text_helper';
|
||||
|
||||
describe('Artifacts block', () => {
|
||||
const Component = Vue.extend(component);
|
||||
|
|
|
@ -3,7 +3,7 @@ import sidebarDetailsBlock from '~/jobs/components/sidebar.vue';
|
|||
import createStore from '~/jobs/store';
|
||||
import job, { stages, jobsInStage } from '../mock_data';
|
||||
import { mountComponentWithStore } from '../../helpers/vue_mount_component_helper';
|
||||
import { trimText } from '../../helpers/vue_component_helper';
|
||||
import { trimText } from '../../helpers/text_helper';
|
||||
|
||||
describe('Sidebar details block', () => {
|
||||
const SidebarComponent = Vue.extend(sidebarDetailsBlock);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import Vue from 'vue';
|
||||
import component from '~/jobs/components/stages_dropdown.vue';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
import mountComponent from '../../helpers/vue_mount_component_helper';
|
||||
|
||||
describe('Stages Dropdown', () => {
|
||||
|
|
|
@ -2,7 +2,7 @@ import Vue from 'vue';
|
|||
import component from '~/reports/components/modal.vue';
|
||||
import state from '~/reports/store/state';
|
||||
import mountComponent from '../../helpers/vue_mount_component_helper';
|
||||
import { trimText } from '../../helpers/vue_component_helper';
|
||||
import { trimText } from '../../helpers/text_helper';
|
||||
|
||||
describe('Grouped Test Reports Modal', () => {
|
||||
const Component = Vue.extend(component);
|
||||
|
|
|
@ -2,7 +2,7 @@ import Vue from 'vue';
|
|||
import component from '~/reports/components/test_issue_body.vue';
|
||||
import createStore from '~/reports/store';
|
||||
import { mountComponentWithStore } from '../../helpers/vue_mount_component_helper';
|
||||
import { trimText } from '../../helpers/vue_component_helper';
|
||||
import { trimText } from '../../helpers/text_helper';
|
||||
import { issue } from '../mock_data/mock_data';
|
||||
|
||||
describe('Test Issue body', () => {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import pipelineComponent from '~/vue_merge_request_widget/components/mr_widget_pipeline.vue';
|
||||
import mountComponent from 'spec/helpers/vue_mount_component_helper';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
import mockData from '../mock_data';
|
||||
|
||||
describe('MRWidgetPipeline', () => {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import $ from 'jquery';
|
||||
import { createLocalVue, shallowMount } from '@vue/test-utils';
|
||||
import ConflictsComponent from '~/vue_merge_request_widget/components/states/mr_widget_conflicts.vue';
|
||||
import { removeBreakLine } from 'spec/helpers/vue_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('MRWidgetConflicts', () => {
|
||||
let vm;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import pipelineBlockedComponent from '~/vue_merge_request_widget/components/states/mr_widget_pipeline_blocked.vue';
|
||||
import mountComponent from 'spec/helpers/vue_mount_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/vue_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('MRWidgetPipelineBlocked', () => {
|
||||
let vm;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import Vue from 'vue';
|
||||
import PipelineFailed from '~/vue_merge_request_widget/components/states/pipeline_failed.vue';
|
||||
import { removeBreakLine } from 'spec/helpers/vue_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('PipelineFailed', () => {
|
||||
describe('template', () => {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import Vue from 'vue';
|
||||
import ShaMismatch from '~/vue_merge_request_widget/components/states/sha_mismatch.vue';
|
||||
import mountComponent from 'spec/helpers/vue_mount_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/vue_component_helper';
|
||||
import { removeBreakLine } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('ShaMismatch', () => {
|
||||
let vm;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import ProjectListItem from '~/vue_shared/components/project_selector/project_list_item.vue';
|
||||
import { shallowMount, createLocalVue } from '@vue/test-utils';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
|
||||
const localVue = createLocalVue();
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ import _ from 'underscore';
|
|||
import ProjectSelector from '~/vue_shared/components/project_selector/project_selector.vue';
|
||||
import ProjectListItem from '~/vue_shared/components/project_selector/project_list_item.vue';
|
||||
import { shallowMount } from '@vue/test-utils';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('ProjectSelector component', () => {
|
||||
let wrapper;
|
||||
|
|
|
@ -3,7 +3,7 @@ import Jed from 'jed';
|
|||
|
||||
import locale from '~/locale';
|
||||
import Translate from '~/vue_shared/translate';
|
||||
import { trimText } from 'spec/helpers/vue_component_helper';
|
||||
import { trimText } from 'spec/helpers/text_helper';
|
||||
|
||||
describe('Vue translate filter', () => {
|
||||
let el;
|
||||
|
|
Loading…
Reference in a new issue