Register routes for integritetspolicy and villkor legal pages.
- Add /integritetspolicy and /villkor to Vue Router - Add Router tests confirming both public legal routes resolve Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
ec62ba7673
commit
a12e07ec1c
2 changed files with 24 additions and 0 deletions
|
|
@ -32,6 +32,18 @@ describe('Router', () => {
|
|||
expect(router.currentRoute.value.name).toBe('forgot-password')
|
||||
})
|
||||
|
||||
it('resolves /integritetspolicy to PrivacyPolicyPage', async () => {
|
||||
await router.push('/integritetspolicy')
|
||||
await router.isReady()
|
||||
expect(router.currentRoute.value.name).toBe('privacy')
|
||||
})
|
||||
|
||||
it('resolves /villkor to TermsOfServicePage', async () => {
|
||||
await router.push('/villkor')
|
||||
await router.isReady()
|
||||
expect(router.currentRoute.value.name).toBe('terms')
|
||||
})
|
||||
|
||||
it('resolves /aterstall-losenord to ResetPasswordPage', async () => {
|
||||
await router.push('/aterstall-losenord?token=abc')
|
||||
await router.isReady()
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ import HomePage from '@/pages/HomePage.vue'
|
|||
import ComposePage from '@/pages/ComposePage.vue'
|
||||
import AboutPage from '@/pages/AboutPage.vue'
|
||||
import ContactPage from '@/pages/ContactPage.vue'
|
||||
import PrivacyPolicyPage from '@/pages/PrivacyPolicyPage.vue'
|
||||
import TermsOfServicePage from '@/pages/TermsOfServicePage.vue'
|
||||
import RegisterPage from '@/pages/RegisterPage.vue'
|
||||
import LoginPage from '@/pages/LoginPage.vue'
|
||||
import ForgotPasswordPage from '@/pages/ForgotPasswordPage.vue'
|
||||
|
|
@ -97,6 +99,16 @@ const router = createRouter({
|
|||
name: 'contact',
|
||||
component: ContactPage,
|
||||
},
|
||||
{
|
||||
path: '/integritetspolicy',
|
||||
name: 'privacy',
|
||||
component: PrivacyPolicyPage,
|
||||
},
|
||||
{
|
||||
path: '/villkor',
|
||||
name: 'terms',
|
||||
component: TermsOfServicePage,
|
||||
},
|
||||
],
|
||||
})
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue