Skip to content

Commit 6183f32

Browse files
committed
test: fix linting errors
1 parent 9cccbae commit 6183f32

File tree

2 files changed

+40
-40
lines changed

2 files changed

+40
-40
lines changed

Diff for: test/specs/config.spec.js

+12-12
Original file line numberDiff line numberDiff line change
@@ -138,17 +138,17 @@ describeWithShallowAndMount('config', (mountingMethod) => {
138138
itSkipIf(
139139
vueVersion < 2.3,
140140
'does not log when component is extended if logModifiedComponents is false', () => {
141-
const ChildComponent = Vue.extend({
142-
template: '<span />'
143-
})
144-
const TestComponent = {
145-
template: '<child-component />',
146-
components: {
147-
ChildComponent
141+
const ChildComponent = Vue.extend({
142+
template: '<span />'
143+
})
144+
const TestComponent = {
145+
template: '<child-component />',
146+
components: {
147+
ChildComponent
148+
}
148149
}
149-
}
150-
config.logModifiedComponents = false
151-
mountingMethod(TestComponent)
152-
expect(consoleError.called).to.equal(false)
153-
})
150+
config.logModifiedComponents = false
151+
mountingMethod(TestComponent)
152+
expect(consoleError.called).to.equal(false)
153+
})
154154
})

Diff for: test/specs/mounting-options/localVue.spec.js

+28-28
Original file line numberDiff line numberDiff line change
@@ -37,36 +37,36 @@ describeWithMountingMethods('options.localVue', (mountingMethod) => {
3737
itSkipIf(
3838
vueVersion < 2.3,
3939
'works correctly with extended children', () => {
40-
const localVue = createLocalVue()
41-
localVue.use(Vuex)
42-
const store = new Vuex.Store({
43-
state: { val: 2 }
44-
})
45-
const ChildComponent = Vue.extend({
46-
template: '<span>{{val}}</span>',
47-
computed: {
48-
val () {
49-
return this.$store.state.val
40+
const localVue = createLocalVue()
41+
localVue.use(Vuex)
42+
const store = new Vuex.Store({
43+
state: { val: 2 }
44+
})
45+
const ChildComponent = Vue.extend({
46+
template: '<span>{{val}}</span>',
47+
computed: {
48+
val () {
49+
return this.$store.state.val
50+
}
51+
}
52+
})
53+
const TestComponent = {
54+
template: '<div><child-component /></div>',
55+
components: {
56+
ChildComponent
5057
}
5158
}
52-
})
53-
const TestComponent = {
54-
template: '<div><child-component /></div>',
55-
components: {
56-
ChildComponent
59+
const wrapper = mountingMethod(TestComponent, {
60+
localVue,
61+
store
62+
})
63+
const HTML = mountingMethod.name === 'renderToString'
64+
? wrapper
65+
: wrapper.html()
66+
if (mountingMethod.name === 'shallowMount') {
67+
expect(HTML).to.not.contain('2')
68+
} else {
69+
expect(HTML).to.contain('2')
5770
}
58-
}
59-
const wrapper = mountingMethod(TestComponent, {
60-
localVue,
61-
store
6271
})
63-
const HTML = mountingMethod.name === 'renderToString'
64-
? wrapper
65-
: wrapper.html()
66-
if (mountingMethod.name === 'shallowMount') {
67-
expect(HTML).to.not.contain('2')
68-
} else {
69-
expect(HTML).to.contain('2')
70-
}
71-
})
7272
})

0 commit comments

Comments
 (0)