Skip to content

Commit

Permalink
test: adding retry when running on CI
Browse files Browse the repository at this point in the history
  • Loading branch information
hung-cybo committed May 7, 2024
1 parent 6bd4b6c commit af43395
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/create-plugin/__e2e__/setup.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const isRunOnActions = () => !!process.env.GITHUB_ACTIONS;

if (isRunOnActions()) {
jest.retryTimes(3, { logErrorsBeforeRetry: true });
}
1 change: 1 addition & 0 deletions packages/create-plugin/jest.e2e.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ const config = {
roots: ["<rootDir>"],
testRegex: "/__e2e__/.*\\.test\\.ts$",
testEnvironment: "./JestCustomEnvironment.js",
setupFilesAfterEnv: ["<rootDir>/__e2e__/setup.ts"],
testTimeout: 120000,
};
module.exports = config;

0 comments on commit af43395

Please sign in to comment.