Skip to content

Commit

Permalink
fix(NcAppNavigationItem): run cypress tests
Browse files Browse the repository at this point in the history
Signed-off-by: Raimund Schlüßler <[email protected]>
  • Loading branch information
raimund-schluessler committed Dec 29, 2023
1 parent 7b7d07f commit 5bc187c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
5 changes: 0 additions & 5 deletions cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,6 @@ export default defineConfig({

},

excludeSpecPattern: [
'cypress/visual/AppNavigationItem.cy.ts',
],


devServer: {
framework: 'vue',
bundler: 'vite',
Expand Down
16 changes: 7 additions & 9 deletions cypress/visual/AppNavigationItem.cy.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { mount } from 'cypress/vue2'
import Vue, { defineComponent } from 'vue'
import VueRouter from 'vue-router'
import { mount } from 'cypress/vue'
import { defineComponent } from 'vue/dist/vue.esm-bundler.js'
import { createRouter, createMemoryHistory} from 'vue-router'

import NcAppNavigationItem from '../../src/components/NcAppNavigationItem/NcAppNavigationItem.vue'

Expand All @@ -17,21 +17,19 @@ describe('NcAppNavigationItem', () => {
components: { NcAppNavigationItem },
})

const router = new VueRouter({
const router = createRouter({
routes: [
{ path: '/' },
{ path: '/foo' },
{ path: '/', component: RouterComponent },
{ path: '/foo', component: RouterComponent },
],
history: createMemoryHistory(),
})

beforeEach(() => {
Vue.use(VueRouter)

mount(RouterComponent as never, {
extensions: {
plugins: [router],
},
router,
})
})

Expand Down

0 comments on commit 5bc187c

Please sign in to comment.