Skip to content

Commit 004f4ae

Browse files
committed
test: try to unflaky
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
1 parent e3444c3 commit 004f4ae

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

cypress.config.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { configureNextcloud, docker, getContainer, getContainerName, runExec, ru
88
import { defineConfig } from 'cypress'
99
import cypressSplit from 'cypress-split'
1010
import vitePreprocessor from 'cypress-vite'
11-
import { existsSync, rmdirSync } from 'node:fs'
11+
import { existsSync, rmSync } from 'node:fs'
1212
import { dirname, join, resolve } from 'node:path'
1313
import { fileURLToPath } from 'node:url'
1414
import { nodePolyfills } from 'vite-plugin-node-polyfills'
@@ -27,7 +27,7 @@ export default defineConfig({
2727

2828
// Tries again when in run mode (cypress run) e.g. on CI
2929
retries: {
30-
runMode: 3,
30+
runMode: 5,
3131
// do not retry in `cypress open`
3232
openMode: 0,
3333
},
@@ -82,11 +82,11 @@ export default defineConfig({
8282
deleteFolder(path: string) {
8383
try {
8484
if (existsSync(path)) {
85-
rmdirSync(path, { maxRetries: 10, recursive: true })
85+
rmSync(path, { maxRetries: 10, recursive: true })
8686
}
8787
return null
8888
} catch (error) {
89-
throw Error(`Error while deleting ${path}. Original error: ${error}`)
89+
throw Error(`Error while deleting ${path}. Original error: ${error}`, { cause: error })
9090
}
9191
},
9292
})

0 commit comments

Comments
 (0)