update password
This commit is contained in:
@@ -5,6 +5,7 @@ import { nextTick } from 'vue'
|
|||||||
import { message } from 'ant-design-vue'
|
import { message } from 'ant-design-vue'
|
||||||
import { ApiError } from '@/types/api'
|
import { ApiError } from '@/types/api'
|
||||||
import { useUserStore } from '@/stores/user'
|
import { useUserStore } from '@/stores/user'
|
||||||
|
import { VALID_TOKEN, VALID_REFRESH_TOKEN } from '@/test/helpers'
|
||||||
|
|
||||||
Object.defineProperty(window, 'matchMedia', {
|
Object.defineProperty(window, 'matchMedia', {
|
||||||
writable: true,
|
writable: true,
|
||||||
@@ -58,7 +59,7 @@ describe('Password Change Page', () => {
|
|||||||
|
|
||||||
async function mountPage() {
|
async function mountPage() {
|
||||||
const store = useUserStore()
|
const store = useUserStore()
|
||||||
store.setToken('h.p.s', 'r.p.s', true)
|
store.setToken(VALID_TOKEN, VALID_REFRESH_TOKEN, true)
|
||||||
store.setUser({ id: 1, username: 'u', email: 'u@e.com', role: 'user', status: 1 })
|
store.setUser({ id: 1, username: 'u', email: 'u@e.com', role: 'user', status: 1 })
|
||||||
|
|
||||||
const { default: PasswordPage } = await import('../password.vue')
|
const { default: PasswordPage } = await import('../password.vue')
|
||||||
|
|||||||
Reference in New Issue
Block a user