From 42cc32ba95d70c104b5a5d459716b2c8d3f2531e Mon Sep 17 00:00:00 2001 From: Tom Milewski Date: Fri, 13 Oct 2023 13:13:07 -0400 Subject: [PATCH] test(repo): Add cmd to clear test cache --- package.json | 1 + packages/chrome-extension/package.json | 1 + packages/clerk-js/package.json | 1 + packages/fastify/package.json | 3 ++- packages/nextjs/package.json | 1 + packages/react/package.json | 1 + packages/sdk-node/package.json | 1 + packages/shared/package.json | 1 + turbo.json | 3 +++ 9 files changed, 12 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 3d2500ad03..a874d33680 100644 --- a/package.json +++ b/package.json @@ -66,6 +66,7 @@ "dev:js": "FORCE_COLOR=1 turbo dev:current --filter=@clerk/clerk-js", "build": "FORCE_COLOR=1 turbo build --concurrency=${TURBO_CONCURRENCY:-80%}", "test": "FORCE_COLOR=1 turbo test --concurrency=${TURBO_CONCURRENCY:-80%}", + "test:cache:clear": "FORCE_COLOR=1 turbo test:cache:clear --continue --concurrency=${TURBO_CONCURRENCY:-80%}", "test:ci": "FORCE_COLOR=1 turbo test --concurrency=${TURBO_CONCURRENCY:-80%}", "test:integration:base": "DEBUG=1 npx playwright test --config integration/playwright.config.ts", "test:integration:generic": "E2E_APP_ID=react.vite.* npm run test:integration:base -- --grep @generic", diff --git a/packages/chrome-extension/package.json b/packages/chrome-extension/package.json index 5a574d3e08..f450e922b9 100644 --- a/packages/chrome-extension/package.json +++ b/packages/chrome-extension/package.json @@ -29,6 +29,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%", "test:coverage": "jest --collectCoverage && open coverage/lcov-report/index.html", "prepublishOnly": "npm run build" diff --git a/packages/clerk-js/package.json b/packages/clerk-js/package.json index 4c455a0321..0f07a1e52d 100644 --- a/packages/clerk-js/package.json +++ b/packages/clerk-js/package.json @@ -37,6 +37,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%", "test:coverage": "jest --collectCoverage && open coverage/lcov-report/index.html", "watch": "webpack --config webpack.config.js --env production --watch" diff --git a/packages/fastify/package.json b/packages/fastify/package.json index 5a348ae163..ec234e2e56 100644 --- a/packages/fastify/package.json +++ b/packages/fastify/package.json @@ -26,7 +26,8 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "publish:local": "npx yalc push --replace --sig", - "test": "jest" + "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr" }, "dependencies": { "@clerk/backend": "0.31.0", diff --git a/packages/nextjs/package.json b/packages/nextjs/package.json index 8fd742b810..f867efda13 100644 --- a/packages/nextjs/package.json +++ b/packages/nextjs/package.json @@ -74,6 +74,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%" }, "dependencies": { diff --git a/packages/react/package.json b/packages/react/package.json index e138d50ae2..4af6ef7abb 100644 --- a/packages/react/package.json +++ b/packages/react/package.json @@ -43,6 +43,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%" }, "dependencies": { diff --git a/packages/sdk-node/package.json b/packages/sdk-node/package.json index 4a84b2db14..e6c7b43659 100644 --- a/packages/sdk-node/package.json +++ b/packages/sdk-node/package.json @@ -44,6 +44,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%" }, "name": "@clerk/clerk-sdk-node", diff --git a/packages/shared/package.json b/packages/shared/package.json index 6b3fb515e5..0edc6b0ca4 100644 --- a/packages/shared/package.json +++ b/packages/shared/package.json @@ -27,6 +27,7 @@ "lint:publint": "publint", "lint:attw": "attw --pack .", "test": "jest", + "test:cache:clear": "jest --clearCache --useStderr", "test:ci": "jest --maxWorkers=70%", "test:coverage": "jest --collectCoverage && open coverage/lcov-report/index.html" }, diff --git a/turbo.json b/turbo.json index 8528e46618..8034355957 100644 --- a/turbo.json +++ b/turbo.json @@ -58,6 +58,9 @@ "dependsOn": ["build"], "outputs": [] }, + "test:cache:clear": { + "cache": false + }, "test:ci": { "dependsOn": ["build"], "outputs": []