router.test.js fix SendOverview

This commit is contained in:
ogerly 2021-10-13 16:47:37 +02:00
parent 907a9fe696
commit b2363198c2

View File

@ -56,7 +56,7 @@ describe('router', () => {
})
it('has twelve routes defined', () => {
expect(routes).toHaveLength(12)
expect(routes).toHaveLength(13)
})
describe('overview', () => {
@ -70,6 +70,17 @@ describe('router', () => {
})
})
describe('send', () => {
it('requires authorization', () => {
expect(routes.find((r) => r.path === '/send').meta.requiresAuth).toBeTruthy()
})
it('loads the "Send" component', async () => {
const component = await routes.find((r) => r.path === '/send').component()
expect(component.default.name).toBe('SendOverview')
})
})
describe('profile', () => {
it('requires authorization', () => {
expect(routes.find((r) => r.path === '/profile').meta.requiresAuth).toBeTruthy()