mirror of
https://github.com/tenrok/vue-meta.git
synced 2026-06-24 23:00:34 +03:00
fix broken tests
This commit is contained in:
@@ -9,13 +9,13 @@ describe('getComponentOption', () => {
|
|||||||
|
|
||||||
it('returns an empty object when no matching options are found', () => {
|
it('returns an empty object when no matching options are found', () => {
|
||||||
component = new Vue()
|
component = new Vue()
|
||||||
const { mergedOption } = getComponentOption({ component, option: 'noop' })
|
const mergedOption = getComponentOption({ component, option: 'noop' })
|
||||||
expect(mergedOption).to.eql({})
|
expect(mergedOption).to.eql({})
|
||||||
})
|
})
|
||||||
|
|
||||||
it('fetches the given option from the given component', () => {
|
it('fetches the given option from the given component', () => {
|
||||||
component = new Vue({ someOption: 'foo' })
|
component = new Vue({ someOption: 'foo' })
|
||||||
const { mergedOption } = getComponentOption({ component, option: 'someOption' })
|
const mergedOption = getComponentOption({ component, option: 'someOption' })
|
||||||
expect(mergedOption).to.eql('foo')
|
expect(mergedOption).to.eql('foo')
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -28,7 +28,7 @@ describe('getComponentOption', () => {
|
|||||||
el: container
|
el: container
|
||||||
})
|
})
|
||||||
|
|
||||||
const { mergedOption } = getComponentOption({ component, option: 'foo', deep: true })
|
const mergedOption = getComponentOption({ component, option: 'foo', deep: true })
|
||||||
expect(mergedOption).to.eql({ bar: 'baz', fizz: 'buzz' })
|
expect(mergedOption).to.eql({ bar: 'baz', fizz: 'buzz' })
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -48,7 +48,7 @@ describe('getComponentOption', () => {
|
|||||||
el: container
|
el: container
|
||||||
})
|
})
|
||||||
|
|
||||||
const { mergedOption } = getComponentOption({
|
const mergedOption = getComponentOption({
|
||||||
component,
|
component,
|
||||||
option: 'foo',
|
option: 'foo',
|
||||||
deep: true,
|
deep: true,
|
||||||
|
|||||||
Reference in New Issue
Block a user