test for layouts/DashboardLayout.spec.js

This commit is contained in:
ogerly 2022-10-24 12:51:01 +02:00
parent 77f627060e
commit 952383792e

View File

@ -1,5 +1,6 @@
import { mount, RouterLinkStub } from '@vue/test-utils'
import App from './App'
import flushPromises from 'flush-promises'
const localVue = global.localVue
const mockStoreCommit = jest.fn()
@ -49,7 +50,8 @@ describe('App', () => {
})
describe('route requires authorization', () => {
beforeEach(() => {
beforeEach(async () => {
await flushPromises()
mocks.$route.meta.requiresAuth = true
wrapper = Wrapper()
})