summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorLukas Eipert <leipert@gitlab.com>2018-05-28 11:48:22 +0200
committerLukas Eipert <leipert@gitlab.com>2018-05-29 18:42:29 +0200
commit9a9f758d9121bcf24fa3fcee6dc724030467a6f3 (patch)
tree8f04b4d2aa799d8523f92179675faf3ae14ee7bd /spec
parent99c4e46d1df36ed7830dfaef2e146177752f244f (diff)
downloadgitlab-ce-9a9f758d9121bcf24fa3fcee6dc724030467a6f3.tar.gz
remove unused createComponentWithMixin from vue spec helpers
Diffstat (limited to 'spec')
-rw-r--r--spec/javascripts/helpers/vue_mount_component_helper.js30
1 files changed, 9 insertions, 21 deletions
diff --git a/spec/javascripts/helpers/vue_mount_component_helper.js b/spec/javascripts/helpers/vue_mount_component_helper.js
index a34a1add4e0..5ba17ecf5b5 100644
--- a/spec/javascripts/helpers/vue_mount_component_helper.js
+++ b/spec/javascripts/helpers/vue_mount_component_helper.js
@@ -1,30 +1,18 @@
-import Vue from 'vue';
-
-const mountComponent = (Component, props = {}, el = null) => new Component({
- propsData: props,
-}).$mount(el);
-
-export const createComponentWithStore = (Component, store, propsData = {}) => new Component({
- store,
- propsData,
-});
+const mountComponent = (Component, props = {}, el = null) =>
+ new Component({
+ propsData: props,
+ }).$mount(el);
-export const createComponentWithMixin = (mixins = [], state = {}, props = {}, template = '<div></div>') => {
- const Component = Vue.extend({
- template,
- mixins,
- data() {
- return props;
- },
+export const createComponentWithStore = (Component, store, propsData = {}) =>
+ new Component({
+ store,
+ propsData,
});
- return mountComponent(Component, props);
-};
-
export const mountComponentWithStore = (Component, { el, props, store }) =>
new Component({
store,
- propsData: props || { },
+ propsData: props || {},
}).$mount(el);
export default mountComponent;