Skip to content

Commit

Permalink
test user list
Browse files Browse the repository at this point in the history
  • Loading branch information
satterly committed Apr 10, 2024
1 parent b159a89 commit 6c190b6
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions tests/unit/components/UserList.spec.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
import { shallowMount } from '@vue/test-utils'
import { shallowMount, createLocalVue } from '@vue/test-utils'
import Vuex from 'vuex'
import UserList from '@/components/UserList.vue'

const localVue = createLocalVue()

localVue.use(Vuex)

describe('UserList', () => {

let store = new Vuex.Store({})

it('renders a div', () => {
const wrapper = shallowMount(UserList)
const wrapper = shallowMount(UserList, { store, localVue })
expect(wrapper.contains('div')).toBe(true)
})
})

0 comments on commit 6c190b6

Please sign in to comment.