Fix tests

This commit is contained in:
Angelina Filippova 2020-11-09 18:55:36 +03:00
parent fdbd5fdaf8
commit c64ccc863c
2 changed files with 6 additions and 2 deletions

View file

@ -106,6 +106,10 @@ export async function deleteUsers(nicknames, authHost, token) {
})
}
export async function listAllTags(authHost, token) {
return Promise.resolve({ data: ['verify', 'mrf_tag:media-force-nsfw'] })
}
export async function tagUser(nickname, tag, authHost, token) {
return Promise.resolve()
}

View file

@ -138,7 +138,7 @@ describe('Users actions', () => {
const dropdownMenuItems = wrapper.findAll(
`.el-table__fixed-body-wrapper table tr:nth-child(2) ul.el-dropdown-menu > li`
)
expect(dropdownMenuItems.length).toBe(7)
expect(dropdownMenuItems.length).toBe(3)
done()
})
@ -271,7 +271,7 @@ describe('Users actions', () => {
expect(wrapper.vm.resetPasswordDialogOpen).toBe(false)
expect(store.state.users.passwordResetToken.token).toBe('')
wrapper.find(htmlElement(1, 12)).trigger('click')
wrapper.find(htmlElement(1, 6)).trigger('click')
await flushPromises()
expect(wrapper.vm.resetPasswordDialogOpen).toBe(true)