coverage search-results.spec.js

This commit is contained in:
Ulf Gebhardt 2021-04-25 16:24:59 +02:00
parent 63d962a69e
commit d2347ba2d8
No known key found for this signature in database
GPG Key ID: 81308EFE29ABFEBD

View File

@ -0,0 +1,31 @@
import { config, mount } from '@vue/test-utils'
import searchResults from './search-results.vue'
const localVue = global.localVue
config.stubs['client-only'] = '<span class="client-only"><slot /></span>'
describe('search-results.vue', () => {
let wrapper
let mocks
beforeEach(() => {
mocks = {
$t: jest.fn(),
}
})
describe('mount', () => {
const Wrapper = () => {
return mount(searchResults, { mocks, localVue })
}
beforeEach(() => {
wrapper = Wrapper()
})
it('renders', () => {
expect(wrapper.findAll('.search-results')).toHaveLength(1)
})
})
})