HelloWorld.spec.js 354 B

1234567891011
  1. import Vue from 'vue'
  2. import HelloWorld from '@/components/HelloWorld'
  3. describe('HelloWorld.vue', () => {
  4. it('should render correct contents', () => {
  5. const Constructor = Vue.extend(HelloWorld)
  6. const vm = new Constructor().$mount()
  7. expect(vm.$el.querySelector('.hello h1').textContent)
  8. .toEqual('Welcome to Your Vue.js App')
  9. })
  10. })