Skip to content

Commit 686b567

Browse files
committed
chore(test): fix Cypress flakyness
Signed-off-by: Grigorii K. Shartsev <[email protected]>
1 parent 3761026 commit 686b567

File tree

8 files changed

+22
-7
lines changed

8 files changed

+22
-7
lines changed

cypress.config.mjs

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,21 @@ export default defineConfig({
7575
define: {
7676
NEXTCLOUD_VERSION: '"32.0.0"',
7777
},
78+
optimizeDeps: {
79+
include: [
80+
'vue',
81+
'@cypress/vue2',
82+
'rehype-highlight',
83+
],
84+
force: true,
85+
},
86+
warmup: {
87+
clientFiles: [
88+
'cypress/support/component.ts',
89+
'cypress/**/*.cy.ts',
90+
'cypress/**/*.cy.js',
91+
],
92+
},
7893
css: {
7994
devSourcemap: true,
8095
preprocessorOptions: {

cypress/component/NcAppSettingsDialog.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6-
import { mount } from 'cypress/vue2'
6+
import { mount } from '@cypress/vue2'
77
import { defineComponent } from 'vue'
88
import NcAppSettingsDialog from '../../src/components/NcAppSettingsDialog/NcAppSettingsDialog.vue'
99
import NcAppSettingsSection from '../../src/components/NcAppSettingsSection/NcAppSettingsSection.vue'

cypress/component/NcDialog.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6-
import { mount } from 'cypress/vue2'
6+
import { mount } from '@cypress/vue2'
77
import NcDialog from '../../src/components/NcDialog/NcDialog.vue'
88

99
describe('NcDialog', () => {

cypress/component/NcModal.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
import type { Component } from 'vue'
77

8-
import { mount } from 'cypress/vue2'
8+
import { mount } from '@cypress/vue2'
99
import NcModal from '../../src/components/NcModal/NcModal.vue'
1010

1111
describe('NcModal', () => {

cypress/component/NcSelect.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6-
import { mount } from 'cypress/vue2'
6+
import { mount } from '@cypress/vue2'
77
import NcSelect from '../../src/components/NcSelect/NcSelect.vue'
88

99
describe('NcSelect', () => {

cypress/component/NcSelectUsers.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6-
import { mount } from 'cypress/vue2'
6+
import { mount } from '@cypress/vue2'
77
import NcSelectUsers from '../../src/components/NcSelectUsers/NcSelectUsers.vue'
88

99
it('emits the search event', async () => {

cypress/component/richtext.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// Markdown guide: https://www.markdownguide.org/basic-syntax/
77
// Reference tests: https://github.com/nextcloud-deps/CDMarkdownKit/tree/master/CDMarkdownKitTests
88

9-
import { mount } from 'cypress/vue2'
9+
import { mount } from '@cypress/vue2'
1010
import NcRichText from '../../src/components/NcRichText/NcRichText.vue'
1111

1212
describe('NcRichText', () => {

cypress/visual/AppNavigationItem.cy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* SPDX-License-Identifier: AGPL-3.0-or-later
44
*/
55

6-
import { mount } from 'cypress/vue2'
6+
import { mount } from '@cypress/vue2'
77
import Vue, { defineComponent } from 'vue'
88
import VueRouter from 'vue-router'
99
import NcAppNavigationItem from '../../src/components/NcAppNavigationItem/NcAppNavigationItem.vue'

0 commit comments

Comments
 (0)