test: update tests
This commit is contained in:
@@ -23,10 +23,10 @@ describe('User.vue', () => {
|
||||
expect(User.name).toBe('User')
|
||||
})
|
||||
it('is Vue instance', () => {
|
||||
expect(wrapper.isVueInstance()).toBe(true)
|
||||
expect(wrapper.vm).toBeTruthy()
|
||||
})
|
||||
it('is User', () => {
|
||||
expect(wrapper.is(User)).toBe(true)
|
||||
expect(wrapper.findComponent(User)).toBeTruthy()
|
||||
})
|
||||
it('should have methods', () => {
|
||||
expect(typeof User.methods.goBack).toEqual('function')
|
||||
|
||||
@@ -21,14 +21,14 @@ describe('Users.vue', () => {
|
||||
localVue,
|
||||
router
|
||||
})
|
||||
expect(wrapper.isVueInstance()).toBe(true)
|
||||
expect(wrapper.vm).toBeTruthy()
|
||||
})
|
||||
it('is Users', () => {
|
||||
const wrapper = shallowMount(Users,{
|
||||
localVue,
|
||||
router
|
||||
})
|
||||
expect(wrapper.is(Users)).toBe(true)
|
||||
expect(wrapper.findComponent(Users)).toBeTruthy()
|
||||
})
|
||||
test('renders correctly', () => {
|
||||
const wrapper = shallowMount(Users, {
|
||||
|
||||
Reference in New Issue
Block a user