mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
coverage search-results.spec.js
This commit is contained in:
parent
63d962a69e
commit
d2347ba2d8
31
webapp/pages/search/search-results.spec.js
Normal file
31
webapp/pages/search/search-results.spec.js
Normal 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)
|
||||
})
|
||||
|
||||
})
|
||||
})
|
||||
Loading…
x
Reference in New Issue
Block a user