15 lines
406 B
JavaScript
15 lines
406 B
JavaScript
import { shallowMount } from '@vue/test-utils'
|
|
import WelcomeMessage from '@/components/Home/WelcomeMessage'
|
|
|
|
describe('WelcomeMessage.vue', () => {
|
|
it('renders props.msg when passed', () => {
|
|
const name = 'tester'
|
|
|
|
const wrapper = shallowMount(WelcomeMessage, {
|
|
propsData: { name }
|
|
})
|
|
|
|
expect(wrapper.text()).toBe('Hello tester from my Vue.js page, built with Webpack 4!')
|
|
})
|
|
})
|