itemengine-cypress-automation 1.0.439-enableGlobalRetriesForTestSuite-90a7672.0 → 1.0.441-enableGlobalRetriesForTestSuite-99752a2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,8 +5,8 @@ function abortEarly() {
|
|
5
5
|
console.log(this)
|
6
6
|
}
|
7
7
|
cy.task('shouldSkip').then(value => {
|
8
|
-
// Don't skip if we're in a retry attempt
|
9
|
-
if (value &&
|
8
|
+
// Don't skip if we're in a retry attempt (currentRetry > 0)
|
9
|
+
if (value && this.currentTest.currentRetry() === 0) this.skip();
|
10
10
|
});
|
11
11
|
};
|
12
12
|
|
@@ -17,7 +17,8 @@ function abortEarlySetup() {
|
|
17
17
|
beforeEach(function() {
|
18
18
|
// Only check skip flag, don't reset it for retries
|
19
19
|
cy.task('shouldSkip').then(value => {
|
20
|
-
if
|
20
|
+
// Don't skip if we're in a retry attempt (currentRetry > 0)
|
21
|
+
if (value && this.currentTest.currentRetry() === 0) this.skip();
|
21
22
|
});
|
22
23
|
});
|
23
24
|
afterEach(abortEarly);
|
package/cypress.config.js
CHANGED
@@ -38,7 +38,7 @@ module.exports = defineConfig({
|
|
38
38
|
watchForFileChanges: false,
|
39
39
|
scrollBehavior: 'center',
|
40
40
|
retries: {
|
41
|
-
runMode:
|
41
|
+
runMode: 3, // Retries for CI/headless runs (cy2 run, cypress run)
|
42
42
|
openMode: 0 // Retries for interactive mode (cypress open)
|
43
43
|
},
|
44
44
|
env: {
|