2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-06-16 16:10:33 +03:00

test: increase coverage, add missing tests

fix: issues discovered by adding missing tests
This commit is contained in:
pimlie
2019-03-08 22:13:21 +01:00
committed by Alexander Lichter
parent ce7eaf56d3
commit 5f8025e126
18 changed files with 494 additions and 112 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
module.exports = {
testEnvironment: 'node',
testEnvironment: 'jest-environment-jsdom-global',
expand: true,
+2 -1
View File
@@ -80,8 +80,9 @@
"eslint-plugin-vue": "^5.2.2",
"esm": "^3.2.5",
"jest": "^24.1.0",
"jest-environment-jsdom": "^24.3.1",
"jest-environment-jsdom-global": "^1.1.1",
"jsdom": "^13.2.0",
"jsdom-global": "^3.0.2",
"rimraf": "^2.6.3",
"rollup": "^1.2.2",
"rollup-plugin-babel": "^4.3.2",
+47 -48
View File
@@ -2,7 +2,7 @@ import { metaInfoOptionKeys, metaInfoAttributeKeys } from '../shared/constants'
import isArray from '../shared/isArray'
import { updateAttribute, updateTag, updateTitle } from './updaters'
const getTag = (tags, tag) => {
function getTag(tags, tag) {
if (!tags[tag]) {
tags[tag] = document.getElementsByTagName(tag)[0]
}
@@ -23,54 +23,53 @@ export default function updateClientMetaInfo(options = {}, newInfo) {
const htmlTag = getTag(tags, 'html')
// if this is not a server render, then update
if (htmlTag.getAttribute(ssrAttribute) === null) {
// initialize tracked changes
const addedTags = {}
const removedTags = {}
for (const type in newInfo) {
// ignore these
if (metaInfoOptionKeys.includes(type)) {
continue
}
if (type === 'title') {
// update the title
updateTitle(newInfo.title)
continue
}
if (metaInfoAttributeKeys.includes(type)) {
const tagName = type.substr(0, 4)
updateAttribute(options, newInfo[type], getTag(tags, tagName))
continue
}
// tags should always be an array, ignore if it isnt
if (!isArray(newInfo[type])) {
continue
}
const { oldTags, newTags } = updateTag(
options,
type,
newInfo[type],
getTag(tags, 'head'),
getTag(tags, 'body')
)
if (newTags.length) {
addedTags[type] = newTags
removedTags[type] = oldTags
}
}
return { addedTags, removedTags }
} else {
// remove the server render attribute so we can update on changes
// if this is a server render, then dont update
if (htmlTag.getAttribute(ssrAttribute)) {
// remove the server render attribute so we can update on (next) changes
htmlTag.removeAttribute(ssrAttribute)
return false
}
return false
// initialize tracked changes
const addedTags = {}
const removedTags = {}
for (const type in newInfo) {
// ignore these
if (metaInfoOptionKeys.includes(type)) {
continue
}
if (type === 'title') {
// update the title
updateTitle(newInfo.title)
continue
}
if (metaInfoAttributeKeys.includes(type)) {
const tagName = type.substr(0, 4)
updateAttribute(options, newInfo[type], getTag(tags, tagName))
continue
}
// tags should always be an array, ignore if it isnt
if (!isArray(newInfo[type])) {
continue
}
const { oldTags, newTags } = updateTag(
options,
type,
newInfo[type],
getTag(tags, 'head'),
getTag(tags, 'body')
)
if (newTags.length) {
addedTags[type] = newTags
removedTags[type] = oldTags
}
}
return { addedTags, removedTags }
}
-4
View File
@@ -38,10 +38,6 @@ export default function getMetaInfo(options = {}, component, escapeSequences = [
}
disableOptionKeys.forEach((disableKey, index) => {
if (!info[disableKey]) {
return
}
if (index === 0) {
ensureIsArray(info, disableKey)
} else if (index === 1) {
+18 -10
View File
@@ -18,16 +18,25 @@ export function arrayMerge({ component, tagIDKeyName, metaTemplateKeyName, conte
const sourceIndex = source.findIndex(item => item[tagIDKeyName] === targetItem[tagIDKeyName])
const sourceItem = source[sourceIndex]
// source doesnt contain any duplicate id's
// or the source item should be ignored
if (sourceIndex === -1 ||
(sourceItem.hasOwnProperty(contentKeyName) && sourceItem[contentKeyName] === undefined) ||
(sourceItem.hasOwnProperty('innerHTML') && sourceItem.innerHTML === undefined)
) {
// source doesnt contain any duplicate vmid's, we can keep targetItem
if (sourceIndex === -1) {
destination.push(targetItem)
return
}
// when sourceItem explictly defines contentKeyName or innerHTML as undefined, its
// an indication that we need to skip the default behaviour
// So we keep the targetItem and ignore/remove the sourceItem
if ((sourceItem.hasOwnProperty(contentKeyName) && sourceItem[contentKeyName] === undefined) ||
(sourceItem.hasOwnProperty('innerHTML') && sourceItem.innerHTML === undefined)) {
destination.push(targetItem)
// remove current index from source array so its not concatenated to destination below
source.splice(sourceIndex, 1)
return
}
// we now know that targetItem is a duplicate and we should ignore it in favor of sourceItem
// if source specifies null as content then ignore both the target as the source
if (sourceItem[contentKeyName] === null || sourceItem.innerHTML === null) {
// remove current index from source array so its not concatenated to destination below
@@ -35,7 +44,6 @@ export function arrayMerge({ component, tagIDKeyName, metaTemplateKeyName, conte
return
}
// we now know that targetItem is a duplicate and we should ignore it in favor of sourceItem
// now we only need to check if the target has a template to combine it with the source
const targetTemplate = targetItem[metaTemplateKeyName]
if (!targetTemplate) {
@@ -64,9 +72,9 @@ export function merge(target, source, options = {}) {
delete source.title
}
for (const attrKey in metaInfoAttributeKeys) {
metaInfoAttributeKeys.forEach((attrKey) => {
if (!source[attrKey]) {
continue
return
}
for (const key in source[attrKey]) {
@@ -74,7 +82,7 @@ export function merge(target, source, options = {}) {
delete source[attrKey][key]
}
}
}
})
return deepmerge(target, source, {
arrayMerge: (t, s) => arrayMerge(options, t, s)
+2
View File
@@ -114,12 +114,14 @@ export default function createMixin(Vue, options) {
// Wait that element is hidden before refreshing meta tags (to support animations)
const interval = setInterval(() => {
if (this.$el && this.$el.offsetParent !== null) {
/* istanbul ignore next line */
return
}
clearInterval(interval)
if (!this.$parent) {
/* istanbul ignore next line */
return
}
+67 -6
View File
@@ -1,5 +1,6 @@
import _getMetaInfo from '../src/shared/getMetaInfo'
import { mount, defaultOptions, loadVueMetaPlugin } from './utils'
import { mount, loadVueMetaPlugin, vmTick } from './utils'
import { defaultOptions } from './utils/constants'
import GoodbyeWorld from './fixtures/goodbye-world.vue'
import HelloWorld from './fixtures/hello-world.vue'
@@ -8,10 +9,31 @@ import Changed from './fixtures/changed.vue'
const getMetaInfo = component => _getMetaInfo(defaultOptions, component)
jest.mock('../src/shared/window', () => ({
hasGlobalWindow: false
}))
describe('client', () => {
let Vue
let html
beforeAll(() => (Vue = loadVueMetaPlugin()))
beforeAll(() => {
Vue = loadVueMetaPlugin()
// force using timers, jest cant mock rAF
delete window.requestAnimationFrame
delete window.cancelAnimationFrame
html = document.createElement('html')
document._getElementsByTagName = document.getElementsByTagName
jest.spyOn(document, 'getElementsByTagName').mockImplementation((tag) => {
if (tag === 'html') {
return [html]
}
return document._getElementsByTagName(tag)
})
})
test('meta-info refreshed on component\'s data change', () => {
const wrapper = mount(HelloWorld, { localVue: Vue })
@@ -78,20 +100,59 @@ describe('client', () => {
expect(metaInfo.title.text()).toEqual('<title data-vue-meta="true">Hello World</title>')
})
test('changed function is called', () => {
test('doesnt update when ssr attribute is set', () => {
html.setAttribute(defaultOptions.ssrAttribute, 'true')
const wrapper = mount(HelloWorld, { localVue: Vue })
const { tags } = wrapper.vm.$meta().refresh()
expect(tags).toBe(false)
})
test('changed function is called', async () => {
const parentComponent = new Vue({ render: h => h('div') })
const wrapper = mount(Changed, { localVue: Vue, parentComponent })
await vmTick(wrapper.vm)
expect(wrapper.vm.$root._vueMeta.initialized).toBe(true)
let context
const changed = jest.fn(function () {
context = this
})
wrapper.setData({ changed })
wrapper.setData({ childVisible: true })
wrapper.setData({ changed, childVisible: true })
jest.runAllTimers()
wrapper.vm.$parent.$meta().refresh()
expect(changed).toHaveBeenCalledTimes(1)
// TODO: this isnt what the docs say
expect(context._uid).not.toBe(wrapper.vm._uid)
})
test('afterNavigation function is called', () => {
const Vue = loadVueMetaPlugin(false, { refreshOnceOnNavigation: true })
const afterNavigation = jest.fn()
const component = Vue.component('nav-component', {
render: h => h('div'),
metaInfo: { afterNavigation }
})
const guards = {}
Vue.prototype.$router = {
beforeEach(fn) {
guards.before = fn
},
afterEach(fn) {
guards.after = fn
}
}
const wrapper = mount(component, { localVue: Vue })
expect(guards.before).toBeDefined()
expect(guards.after).toBeDefined()
guards.before(null, null, () => {})
expect(wrapper.vm.$root._vueMeta.paused).toBe(true)
guards.after()
expect(afterNavigation).toHaveBeenCalled()
})
})
+6 -2
View File
@@ -1,5 +1,6 @@
import _getMetaInfo from '../src/shared/getMetaInfo'
import { defaultOptions, loadVueMetaPlugin } from './utils'
import { loadVueMetaPlugin } from './utils'
import { defaultOptions } from './utils/constants'
const getMetaInfo = (component, escapeSequences) => _getMetaInfo(defaultOptions, component, escapeSequences)
@@ -11,6 +12,7 @@ describe('escaping', () => {
test('special chars are escaped unless disabled', () => {
const component = new Vue({
metaInfo: {
htmlAttrs: { key: 1 },
title: 'Hello & Goodbye',
script: [{ innerHTML: 'Hello & Goodbye' }],
__dangerouslyDisableSanitizers: ['script']
@@ -21,7 +23,9 @@ describe('escaping', () => {
title: 'Hello &amp; Goodbye',
titleChunk: 'Hello & Goodbye',
titleTemplate: '%s',
htmlAttrs: {},
htmlAttrs: {
key: 1
},
headAttrs: {},
bodyAttrs: {},
meta: [],
+1 -1
View File
@@ -1,5 +1,5 @@
import _generateServerInjector from '../src/server/generateServerInjector'
import { defaultOptions } from './utils'
import { defaultOptions } from './utils/constants'
import metaInfoData from './utils/meta-info-data'
const generateServerInjector = (type, data) => _generateServerInjector(defaultOptions, type, data)
+47 -5
View File
@@ -1,4 +1,5 @@
import getComponentOption from '../src/shared/getComponentOption'
import inMetaInfoBranch from '../src/shared/inMetaInfoBranch'
import { mount, getVue, loadVueMetaPlugin } from './utils'
describe('getComponentOption', () => {
@@ -6,20 +7,20 @@ describe('getComponentOption', () => {
beforeAll(() => (Vue = getVue()))
it('returns an empty object when no matching options are found', () => {
test('returns an empty object when no matching options are found', () => {
const component = new Vue()
const mergedOption = getComponentOption({ component, keyName: 'noop' })
expect(mergedOption).toEqual({})
})
it('fetches the given option from the given component', () => {
test('fetches the given option from the given component', () => {
const component = new Vue({ someOption: { foo: 'bar' } })
const mergedOption = getComponentOption({ component, keyName: 'someOption' })
expect(mergedOption.foo).toBeDefined()
expect(mergedOption.foo).toEqual('bar')
})
it('calls a function option, injecting the component as context', () => {
test('calls a function option, injecting the component as context', () => {
const component = new Vue({
name: 'Foobar',
someFunc() {
@@ -32,7 +33,7 @@ describe('getComponentOption', () => {
expect(mergedOption.opt).toEqual('Foobar')
})
it('fetches deeply nested component options and merges them', () => {
test('fetches deeply nested component options and merges them', () => {
const localVue = loadVueMetaPlugin(true, { keyName: 'foo' })
localVue.component('merge-child', { render: h => h('div'), foo: { bar: 'baz' } })
@@ -47,7 +48,8 @@ describe('getComponentOption', () => {
expect(mergedOption).toEqual({ bar: 'baz', fizz: 'buzz' })
})
it('allows for a custom array merge strategy', () => {
/* this undocumented functionality has been removed
test('allows for a custom array merge strategy', () => {
const localVue = loadVueMetaPlugin(false, { keyName: 'foo' })
localVue.component('array-child', {
render: h => h('div'),
@@ -81,5 +83,45 @@ describe('getComponentOption', () => {
{ name: 'flower', content: 'tulip' },
{ name: 'flower', content: 'rose' }
] })
}) */
test('only traverses branches with metaInfo components', () => {
const localVue = loadVueMetaPlugin(false, { keyName: 'foo' })
localVue.component('meta-child', {
foo: { bar: 'baz' },
render(h) {
return h('div', this.$slots.default)
}
})
localVue.component('nometa-child', {
render(h) {
return h('div', this.$slots.default)
}
})
const component = localVue.component('parent', {
render: h => h('div', null, [
h('meta-child', null, [ h('nometa-child') ]),
h('nometa-child', null, [ h('meta-child') ]),
h('nometa-child')
])
})
const wrapper = mount(component, { localVue })
const mergedOption = getComponentOption({ component: wrapper.vm, keyName: 'foo' })
expect(mergedOption).toEqual({ bar: 'baz' })
expect(wrapper.vm.$children[0]._vueMeta).toBe(true)
expect(wrapper.vm.$children[1]._vueMeta).toBe(false)
expect(wrapper.vm.$children[2]._vueMeta).toBeUndefined()
expect(inMetaInfoBranch(wrapper.vm.$children[0])).toBe(true)
expect(inMetaInfoBranch(wrapper.vm.$children[0].$children[0])).toBe(false)
expect(inMetaInfoBranch(wrapper.vm.$children[1])).toBe(true)
expect(inMetaInfoBranch(wrapper.vm.$children[1].$children[0])).toBe(true)
expect(inMetaInfoBranch(wrapper.vm.$children[2])).toBe(false)
})
})
+66 -3
View File
@@ -1,5 +1,6 @@
import _getMetaInfo from '../src/shared/getMetaInfo'
import { defaultOptions, loadVueMetaPlugin } from './utils'
import { loadVueMetaPlugin } from './utils'
import { defaultOptions } from './utils/constants'
const getMetaInfo = component => _getMetaInfo(defaultOptions, component)
@@ -593,6 +594,60 @@ describe('getMetaInfo', () => {
})
})
test('properly uses meta templates with one-level-deep nested children when parent has no template', () => {
Vue.component('merge-child', {
render: h => h('div'),
metaInfo: {
title: 'Hello',
meta: [
{
vmid: 'og:title',
property: 'og:title',
content: 'An important title!',
template: chunk => `${chunk} - My page`
}
]
}
})
const component = new Vue({
metaInfo: {
meta: [
{
vmid: 'og:title',
property: 'og:title',
content: 'Test title'
}
]
},
el: document.createElement('div'),
render: h => h('div', null, [h('merge-child')])
})
expect(getMetaInfo(component)).toEqual({
title: 'Hello',
titleChunk: 'Hello',
titleTemplate: '%s',
htmlAttrs: {},
headAttrs: {},
bodyAttrs: {},
meta: [
{
vmid: 'og:title',
property: 'og:title',
content: 'An important title! - My page'
}
],
base: [],
link: [],
style: [],
script: [],
noscript: [],
__dangerouslyDisableSanitizers: [],
__dangerouslyDisableSanitizersByTagID: {}
})
})
test('no errors when metaInfo returns nothing', () => {
const component = new Vue({
metaInfo() {},
@@ -623,6 +678,9 @@ describe('getMetaInfo', () => {
render: h => h('div'),
metaInfo: {
title: undefined,
bodyAttrs: {
class: undefined
},
meta: [
{
vmid: 'og:title',
@@ -635,6 +693,9 @@ describe('getMetaInfo', () => {
const component = new Vue({
metaInfo: {
title: 'Hello',
bodyAttrs: {
class: 'class'
},
meta: [
{
vmid: 'og:title',
@@ -652,9 +713,11 @@ describe('getMetaInfo', () => {
title: 'Hello',
titleChunk: 'Hello',
titleTemplate: '%s',
htmlAttrs: {},
bodyAttrs: {
class: 'class'
},
headAttrs: {},
bodyAttrs: {},
htmlAttrs: {},
meta: [
{
vmid: 'og:title',
+2 -1
View File
@@ -1,6 +1,7 @@
import triggerUpdate from '../src/client/triggerUpdate'
import batchUpdate from '../src/client/batchUpdate'
import { mount, defaultOptions, vmTick, VueMetaBrowserPlugin, loadVueMetaPlugin } from './utils'
import { mount, vmTick, VueMetaBrowserPlugin, loadVueMetaPlugin } from './utils'
import { defaultOptions } from './utils/constants'
jest.mock('../src/client/triggerUpdate')
jest.mock('../src/client/batchUpdate')
+13 -1
View File
@@ -1,4 +1,5 @@
import { mount, defaultOptions, VueMetaServerPlugin, loadVueMetaPlugin } from './utils'
import { mount, VueMetaServerPlugin, loadVueMetaPlugin } from './utils'
import { defaultOptions } from './utils/constants'
jest.mock('../package.json', () => ({
version: 'test-version'
@@ -13,6 +14,17 @@ describe('plugin', () => {
test('is loaded', () => {
const instance = new Vue()
expect(instance.$meta).toEqual(expect.any(Function))
expect(instance.$meta().inject).toEqual(expect.any(Function))
expect(instance.$meta().refresh).toEqual(expect.any(Function))
expect(instance.$meta().getOptions).toEqual(expect.any(Function))
expect(instance.$meta().inject()).toBeDefined()
expect(instance.$meta().refresh()).toBeDefined()
const options = instance.$meta().getOptions()
expect(options).toBeDefined()
expect(options.keyName).toBe(defaultOptions.keyName)
})
test('component has _hasMetaInfo set to true', () => {
+1 -1
View File
@@ -1,5 +1,5 @@
import _updateClientMetaInfo from '../src/client/updateClientMetaInfo'
import { defaultOptions } from './utils'
import { defaultOptions } from './utils/constants'
import metaInfoData from './utils/meta-info-data'
const updateClientMetaInfo = (type, data) => _updateClientMetaInfo(defaultOptions, { [type]: data })
+1 -18
View File
@@ -2,15 +2,7 @@ import { mount, createLocalVue } from '@vue/test-utils'
import { renderToString } from '@vue/server-test-utils'
import VueMetaBrowserPlugin from '../../src/browser'
import VueMetaServerPlugin from '../../src'
import {
keyName,
attribute,
ssrAttribute,
tagIDKeyName,
metaTemplateKeyName,
contentKeyName
} from '../../src/shared/constants'
import { defaultOptions } from './constants'
export {
mount,
@@ -19,15 +11,6 @@ export {
VueMetaServerPlugin
}
export const defaultOptions = {
keyName,
attribute,
ssrAttribute,
tagIDKeyName,
metaTemplateKeyName,
contentKeyName
}
export function getVue() {
return createLocalVue()
}
+1 -1
View File
@@ -1,4 +1,4 @@
import { defaultOptions } from './'
import { defaultOptions } from './constants'
const metaInfoData = {
title: {
-4
View File
@@ -1,5 +1 @@
import jsdom from 'jsdom-global'
jsdom()
jest.useFakeTimers()
+219 -5
View File
@@ -823,6 +823,92 @@
lodash "^4.17.11"
to-fast-properties "^2.0.0"
"@cnakazawa/watch@^1.0.3":
version "1.0.3"
resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.3.tgz#099139eaec7ebf07a27c1786a3ff64f39464d2ef"
integrity sha512-r5160ogAvGyHsal38Kux7YYtodEKOj89RGb28ht1jh3SJb08VwRwAKKJL0bGb04Zd/3r9FL3BFIc3bBidYffCA==
dependencies:
exec-sh "^0.3.2"
minimist "^1.2.0"
"@jest/console@^24.3.0":
version "24.3.0"
resolved "https://registry.yarnpkg.com/@jest/console/-/console-24.3.0.tgz#7bd920d250988ba0bf1352c4493a48e1cb97671e"
integrity sha512-NaCty/OOei6rSDcbPdMiCbYCI0KGFGPgGO6B09lwWt5QTxnkuhKYET9El5u5z1GAcSxkQmSMtM63e24YabCWqA==
dependencies:
"@jest/source-map" "^24.3.0"
"@types/node" "*"
chalk "^2.0.1"
slash "^2.0.0"
"@jest/environment@^24.3.1":
version "24.3.1"
resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.3.1.tgz#1fbda3ec8fb8ffbaee665d314da91d662227e11e"
integrity sha512-M8bqEkQqPwZVhMMFMqqCnzqIZtuM5vDMfFQ9ZvnEfRT+2T1zTA4UAOH/V4HagEi6S3BCd/mdxFdYmPgXf7GKCA==
dependencies:
"@jest/fake-timers" "^24.3.0"
"@jest/transform" "^24.3.1"
"@jest/types" "^24.3.0"
"@types/node" "*"
jest-mock "^24.3.0"
"@jest/fake-timers@^24.3.0":
version "24.3.0"
resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.3.0.tgz#0a7f8b877b78780c3fa5c3f8683cc0aaf9488331"
integrity sha512-rHwVI17dGMHxHzfAhnZ04+wFznjFfZ246QugeBnbiYr7/bDosPD2P1qeNjWnJUUcfl0HpS6kkr+OB/mqSJxQFg==
dependencies:
"@jest/types" "^24.3.0"
"@types/node" "*"
jest-message-util "^24.3.0"
jest-mock "^24.3.0"
"@jest/source-map@^24.3.0":
version "24.3.0"
resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-24.3.0.tgz#563be3aa4d224caf65ff77edc95cd1ca4da67f28"
integrity sha512-zALZt1t2ou8le/crCeeiRYzvdnTzaIlpOWaet45lNSqNJUnXbppUUFR4ZUAlzgDmKee4Q5P/tKXypI1RiHwgag==
dependencies:
callsites "^3.0.0"
graceful-fs "^4.1.15"
source-map "^0.6.0"
"@jest/test-result@^24.3.0":
version "24.3.0"
resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.3.0.tgz#4c0b1c9716212111920f7cf8c4329c69bc81924a"
integrity sha512-j7UZ49T8C4CVipEY99nLttnczVTtLyVzFfN20OiBVn7awOs0U3endXSTq7ouPrLR5y4YjI5GDcbcvDUjgeamzg==
dependencies:
"@jest/console" "^24.3.0"
"@jest/types" "^24.3.0"
"@types/istanbul-lib-coverage" "^1.1.0"
"@jest/transform@^24.3.1":
version "24.3.1"
resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.3.1.tgz#ce9e1329eb5e640f493bcd5c8eb9970770959bfc"
integrity sha512-PpjylI5goT4Si69+qUjEeHuKjex0LjjrqJzrMYzlOZn/+SCumGKuGC0UQFeEPThyGsFvWH1Q4gj0R66eOHnIpw==
dependencies:
"@babel/core" "^7.1.0"
"@jest/types" "^24.3.0"
babel-plugin-istanbul "^5.1.0"
chalk "^2.0.1"
convert-source-map "^1.4.0"
fast-json-stable-stringify "^2.0.0"
graceful-fs "^4.1.15"
jest-haste-map "^24.3.1"
jest-regex-util "^24.3.0"
jest-util "^24.3.0"
micromatch "^3.1.10"
realpath-native "^1.1.0"
slash "^2.0.0"
source-map "^0.6.1"
write-file-atomic "2.4.1"
"@jest/types@^24.3.0":
version "24.3.0"
resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.3.0.tgz#3f6e117e47248a9a6b5f1357ec645bd364f7ad23"
integrity sha512-VoO1F5tU2n/93QN/zaZ7Q8SeV/Rj+9JJOgbvKbBwy4lenvmdj1iDaQEPXGTKrO6OSvDeb2drTFipZJYxgo6kIQ==
dependencies:
"@types/istanbul-lib-coverage" "^1.1.0"
"@types/yargs" "^12.0.9"
"@nuxt/babel-preset-app@^2.4.5":
version "2.4.5"
resolved "https://registry.yarnpkg.com/@nuxt/babel-preset-app/-/babel-preset-app-2.4.5.tgz#707043fe4686b7375df0917cca9134b7681ae9bf"
@@ -865,6 +951,11 @@
resolved "https://registry.yarnpkg.com/@types/estree/-/estree-0.0.39.tgz#e177e699ee1b8c22d23174caaa7422644389509f"
integrity sha512-EYNwp3bU+98cpU4lAWYYL7Zz+2gryWH1qbdDTidVd6hkiR6weksdbMadyXKXNPEkQFhXM+hVO9ZygomHXp+AIw==
"@types/istanbul-lib-coverage@^1.1.0":
version "1.1.0"
resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-1.1.0.tgz#2cc2ca41051498382b43157c8227fea60363f94a"
integrity sha512-ohkhb9LehJy+PA40rDtGAji61NCgdtKLAlFoYp4cnuuQEswwdK3vz9SOIkkyc3wrk8dzjphQApNs56yyXLStaQ==
"@types/node@*", "@types/node@^10.11.7":
version "10.12.24"
resolved "https://registry.yarnpkg.com/@types/node/-/node-10.12.24.tgz#b13564af612a22a20b5d95ca40f1bffb3af315cf"
@@ -875,6 +966,11 @@
resolved "https://registry.yarnpkg.com/@types/semver/-/semver-5.5.0.tgz#146c2a29ee7d3bae4bf2fcb274636e264c813c45"
integrity sha512-41qEJgBH/TWgo5NFSvBCJ1qkoi3Q6ONSF2avrHq1LVEZfYpdHmj0y9SuTK+u9ZhG1sYQKBL1AWXKyLWP4RaUoQ==
"@types/stack-utils@^1.0.1":
version "1.0.1"
resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-1.0.1.tgz#0a851d3bd96498fa25c33ab7278ed3bd65f06c3e"
integrity sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw==
"@types/strip-bom@^3.0.0":
version "3.0.0"
resolved "https://registry.yarnpkg.com/@types/strip-bom/-/strip-bom-3.0.0.tgz#14a8ec3956c2e81edb7520790aecf21c290aebd2"
@@ -885,6 +981,11 @@
resolved "https://registry.yarnpkg.com/@types/strip-json-comments/-/strip-json-comments-0.0.30.tgz#9aa30c04db212a9a0649d6ae6fd50accc40748a1"
integrity sha512-7NQmHra/JILCd1QqpSzl8+mJRc8ZHz3uDm8YV1Ks9IhK0epEiTw8aIErbvH9PI+6XbqhyIQy3462nEsn7UVzjQ==
"@types/yargs@^12.0.9":
version "12.0.9"
resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-12.0.9.tgz#693e76a52f61a2f1e7fb48c0eef167b95ea4ffd0"
integrity sha512-sCZy4SxP9rN2w30Hlmg5dtdRwgYQfYRiLo9usw8X9cxlf+H4FqM1xX7+sNH7NNKVdbXMJWqva7iyy+fxh/V7fA==
"@vue/babel-helper-vue-jsx-merge-props@^1.0.0-beta.2":
version "1.0.0-beta.2"
resolved "https://registry.yarnpkg.com/@vue/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-1.0.0-beta.2.tgz#f3e20d77b89ddb7a4b9b7a75372f05cd3ac22d92"
@@ -2357,6 +2458,11 @@ exec-sh@^0.2.0:
dependencies:
merge "^1.2.0"
exec-sh@^0.3.2:
version "0.3.2"
resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.3.2.tgz#6738de2eb7c8e671d0366aea0b0db8c6f7d7391b"
integrity sha512-9sLAvzhI5nc8TpuQUh4ahMdCrWT00wPWz7j47/emR5+2qEfoZP5zzUXvx+vdx+H6ohhnsYC31iX04QLYJK8zTg==
execa@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8"
@@ -3508,6 +3614,11 @@ jest-each@^24.0.0:
jest-util "^24.0.0"
pretty-format "^24.0.0"
jest-environment-jsdom-global@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/jest-environment-jsdom-global/-/jest-environment-jsdom-global-1.1.1.tgz#c0b5fd969ace23137fd9c4a3b8e3367a54b4ed15"
integrity sha512-7+M6yMM6vpHfaR9ymrjobx1kG3TQyMpSu9yH7bz9bVHsBMUEdiBOmf6qVvyi8z09delLmHuPQpUFYm5SIGSzhQ==
jest-environment-jsdom@^24.0.0:
version "24.0.0"
resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.0.0.tgz#5affa0654d6e44cd798003daa1a8701dbd6e4d11"
@@ -3517,6 +3628,18 @@ jest-environment-jsdom@^24.0.0:
jest-util "^24.0.0"
jsdom "^11.5.1"
jest-environment-jsdom@^24.3.1:
version "24.3.1"
resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.3.1.tgz#49826bcf12fb3e38895f1e2aaeb52bde603cc2e4"
integrity sha512-rz2OSYJiQerDqWDwjisqRwhVNpwkqFXdtyMzEuJ47Ip9NRpRQ+qy7/+zFujPUy/Z+zjWRO5seHLB/dOD4VpEVg==
dependencies:
"@jest/environment" "^24.3.1"
"@jest/fake-timers" "^24.3.0"
"@jest/types" "^24.3.0"
jest-mock "^24.3.0"
jest-util "^24.3.0"
jsdom "^11.5.1"
jest-environment-node@^24.0.0:
version "24.0.0"
resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.0.0.tgz#330948980656ed8773ce2e04eb597ed91e3c7190"
@@ -3544,6 +3667,21 @@ jest-haste-map@^24.0.0:
micromatch "^3.1.10"
sane "^3.0.0"
jest-haste-map@^24.3.1:
version "24.3.1"
resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.3.1.tgz#b4a66dbe1e6bc45afb9cd19c083bff81cdd535a1"
integrity sha512-OTMQle+astr1lWKi62Ccmk2YWn6OtUoU/8JpJdg8zdsnpFIry/k0S4sQ4nWocdM07PFdvqcthWc78CkCE6sXvA==
dependencies:
"@jest/types" "^24.3.0"
fb-watchman "^2.0.0"
graceful-fs "^4.1.15"
invariant "^2.2.4"
jest-serializer "^24.3.0"
jest-util "^24.3.0"
jest-worker "^24.3.1"
micromatch "^3.1.10"
sane "^4.0.3"
jest-jasmine2@^24.1.0:
version "24.1.0"
resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.1.0.tgz#8377324b967037c440f0a549ee0bbd9912055db6"
@@ -3590,16 +3728,42 @@ jest-message-util@^24.0.0:
slash "^2.0.0"
stack-utils "^1.0.1"
jest-message-util@^24.3.0:
version "24.3.0"
resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.3.0.tgz#e8f64b63ebc75b1a9c67ee35553752596e70d4a9"
integrity sha512-lXM0YgKYGqN5/eH1NGw4Ix+Pk2I9Y77beyRas7xM24n+XTTK3TbT0VkT3L/qiyS7WkW0YwyxoXnnAaGw4hsEDA==
dependencies:
"@babel/code-frame" "^7.0.0"
"@jest/test-result" "^24.3.0"
"@jest/types" "^24.3.0"
"@types/stack-utils" "^1.0.1"
chalk "^2.0.1"
micromatch "^3.1.10"
slash "^2.0.0"
stack-utils "^1.0.1"
jest-mock@^24.0.0:
version "24.0.0"
resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.0.0.tgz#9a4b53e01d66a0e780f7d857462d063e024c617d"
integrity sha512-sQp0Hu5fcf5NZEh1U9eIW2qD0BwJZjb63Yqd98PQJFvf/zzUTBoUAwv/Dc/HFeNHIw1f3hl/48vNn+j3STaI7A==
jest-mock@^24.3.0:
version "24.3.0"
resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.3.0.tgz#95a86b6ad474e3e33227e6dd7c4ff6b07e18d3cb"
integrity sha512-AhAo0qjbVWWGvcbW5nChFjR0ObQImvGtU6DodprNziDOt+pP0CBdht/sYcNIOXeim8083QUi9bC8QdKB8PTK4Q==
dependencies:
"@jest/types" "^24.3.0"
jest-regex-util@^24.0.0:
version "24.0.0"
resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-24.0.0.tgz#4feee8ec4a358f5bee0a654e94eb26163cb9089a"
integrity sha512-Jv/uOTCuC+PY7WpJl2mpoI+WbY2ut73qwwO9ByJJNwOCwr1qWhEW2Lyi2S9ZewUdJqeVpEBisdEVZSI+Zxo58Q==
jest-regex-util@^24.3.0:
version "24.3.0"
resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-24.3.0.tgz#d5a65f60be1ae3e310d5214a0307581995227b36"
integrity sha512-tXQR1NEOyGlfylyEjg1ImtScwMq8Oh3iJbGTjN7p0J23EuVX1MA8rwU69K4sLbCmwzgCUbVkm0FkSF9TdzOhtg==
jest-resolve-dependencies@^24.1.0:
version "24.1.0"
resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.1.0.tgz#78f738a2ec59ff4d00751d9da56f176e3f589f6c"
@@ -3670,6 +3834,11 @@ jest-serializer@^24.0.0:
resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.0.0.tgz#522c44a332cdd194d8c0531eb06a1ee5afb4256b"
integrity sha512-9FKxQyrFgHtx3ozU+1a8v938ILBE7S8Ko3uiAVjT8Yfi2o91j/fj81jacCQZ/Ihjiff/VsUCXVgQ+iF1XdImOw==
jest-serializer@^24.3.0:
version "24.3.0"
resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.3.0.tgz#074e307300d1451617cf2630d11543ee4f74a1c8"
integrity sha512-RiSpqo2OFbVLJN/PgAOwQIUeHDfss6NBUDTLhjiJM8Bb5rMrwRqHfkaqahIsOf9cXXB5UjcqDCzbQ7AIoMqWkg==
jest-snapshot@^24.1.0:
version "24.1.0"
resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.1.0.tgz#85e22f810357aa5994ab61f236617dc2205f2f5b"
@@ -3700,6 +3869,25 @@ jest-util@^24.0.0:
slash "^2.0.0"
source-map "^0.6.0"
jest-util@^24.3.0:
version "24.3.0"
resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.3.0.tgz#a549ae9910fedbd4c5912b204bb1bcc122ea0057"
integrity sha512-eKIAC+MTKWZthUUVOwZ3Tc5a0cKMnxalQHr6qZ4kPzKn6k09sKvsmjCygqZ1SxVVfUKoa8Sfn6XDv9uTJ1iXTg==
dependencies:
"@jest/console" "^24.3.0"
"@jest/fake-timers" "^24.3.0"
"@jest/source-map" "^24.3.0"
"@jest/test-result" "^24.3.0"
"@jest/types" "^24.3.0"
"@types/node" "*"
callsites "^3.0.0"
chalk "^2.0.1"
graceful-fs "^4.1.15"
is-ci "^2.0.0"
mkdirp "^0.5.1"
slash "^2.0.0"
source-map "^0.6.0"
jest-validate@^24.0.0:
version "24.0.0"
resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.0.0.tgz#aa8571a46983a6538328fef20406b4a496b6c020"
@@ -3729,6 +3917,15 @@ jest-worker@^24.0.0:
merge-stream "^1.0.1"
supports-color "^6.1.0"
jest-worker@^24.3.1:
version "24.3.1"
resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-24.3.1.tgz#c1759dd2b1d5541b09a2e5e1bc3288de6c9d8632"
integrity sha512-ZCoAe/iGLzTJvWHrO8fyx3bmEQhpL16SILJmWHKe8joHhyF3z00psF1sCRT54DoHw5GJG0ZpUtGy+ylvwA4haA==
dependencies:
"@types/node" "*"
merge-stream "^1.0.1"
supports-color "^6.1.0"
jest@^24.1.0:
version "24.1.0"
resolved "https://registry.yarnpkg.com/jest/-/jest-24.1.0.tgz#b1e1135caefcf2397950ecf7f90e395fde866fd2"
@@ -3776,11 +3973,6 @@ jsbn@~0.1.0:
resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513"
integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM=
jsdom-global@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/jsdom-global/-/jsdom-global-3.0.2.tgz#6bd299c13b0c4626b2da2c0393cd4385d606acb9"
integrity sha1-a9KZwTsMRiay2iwDk81DhdYGrLk=
jsdom@^11.5.1:
version "11.12.0"
resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.12.0.tgz#1a80d40ddd378a1de59656e9e6dc5a3ba8657bc8"
@@ -4951,6 +5143,13 @@ realpath-native@^1.0.0, realpath-native@^1.0.2:
dependencies:
util.promisify "^1.0.0"
realpath-native@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/realpath-native/-/realpath-native-1.1.0.tgz#2003294fea23fb0672f2476ebe22fcf498a2d65c"
integrity sha512-wlgPA6cCIIg9gKz0fgAPjnzh4yR/LnXovwuo9hvyGvx3h8nX4+/iLZplfUWasXpqD8BdnGnP5njOFjkUwPzvjA==
dependencies:
util.promisify "^1.0.0"
regenerate-unicode-properties@^7.0.0:
version "7.0.0"
resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-7.0.0.tgz#107405afcc4a190ec5ed450ecaa00ed0cafa7a4c"
@@ -5318,6 +5517,21 @@ sane@^3.0.0:
optionalDependencies:
fsevents "^1.2.3"
sane@^4.0.3:
version "4.0.3"
resolved "https://registry.yarnpkg.com/sane/-/sane-4.0.3.tgz#e878c3f19e25cc57fbb734602f48f8a97818b181"
integrity sha512-hSLkC+cPHiBQs7LSyXkotC3UUtyn8C4FMn50TNaacRyvBlI+3ebcxMpqckmTdtXVtel87YS7GXN3UIOj7NiGVQ==
dependencies:
"@cnakazawa/watch" "^1.0.3"
anymatch "^2.0.0"
capture-exit "^1.2.0"
exec-sh "^0.3.2"
execa "^1.0.0"
fb-watchman "^2.0.0"
micromatch "^3.1.4"
minimist "^1.1.1"
walker "~1.0.5"
sax@^1.2.4:
version "1.2.4"
resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9"