Skip to content

Commit 4d4f35c

Browse files
chore: clean CICD
1 parent 61f2690 commit 4d4f35c

File tree

25 files changed

+23
-42
lines changed

25 files changed

+23
-42
lines changed

.github/workflows/test-with-real-npm.yml

Lines changed: 23 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,11 @@ permissions:
1111
id-token: write
1212
contents: write
1313

14+
env:
15+
REAL_NPM: true
16+
DISABLE_PARALLEL_DEPLOY: false
17+
node_version: 20
18+
1419
jobs:
1520
test-cdk-basic:
1621
runs-on: ubuntu-latest
@@ -21,7 +26,7 @@ jobs:
2126
- name: Use Node.js
2227
uses: actions/setup-node@v4
2328
with:
24-
node-version: "20"
29+
node-version: ${{ env.node_version }}
2530
registry-url: "https://registry.npmjs.org"
2631
- name: Move vite.config.ts to test folder
2732
run: |
@@ -61,10 +66,10 @@ jobs:
6166
run: npm run deploy
6267
working-directory: test/cdk-basic
6368
- name: Test
64-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 cdk-basic.test.ts
69+
run: npx vitest --retry 1 cdk-basic.test.ts
6570
working-directory: test
6671
- name: Test - observable mode
67-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 cdk-basic.test.ts
72+
run: OBSERVABLE_MODE=true npx vitest --retry 1 cdk-basic.test.ts
6873
working-directory: test
6974

7075
test-sls-basic:
@@ -76,7 +81,7 @@ jobs:
7681
- name: Use Node.js
7782
uses: actions/setup-node@v4
7883
with:
79-
node-version: "20"
84+
node-version: ${{ env.node_version }}
8085
registry-url: "https://registry.npmjs.org"
8186
- name: Move vite.config.ts to test folder
8287
run: |
@@ -117,10 +122,10 @@ jobs:
117122
run: npm run deploy
118123
working-directory: test/sls-basic
119124
- name: Test
120-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 sls-basic.test.ts
125+
run: npx vitest --retry 1 sls-basic.test.ts
121126
working-directory: test
122127
- name: Test - observable mode
123-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 sls-basic.test.ts
128+
run: OBSERVABLE_MODE=true npx vitest --retry 1 sls-basic.test.ts
124129
working-directory: test
125130

126131
test-sls-esbuild-cjs:
@@ -132,7 +137,7 @@ jobs:
132137
- name: Use Node.js
133138
uses: actions/setup-node@v4
134139
with:
135-
node-version: "20"
140+
node-version: ${{ env.node_version }}
136141
registry-url: "https://registry.npmjs.org"
137142
- name: Move vite.config.ts to test folder
138143
run: |
@@ -173,10 +178,10 @@ jobs:
173178
run: npm run deploy
174179
working-directory: test/sls-esbuild-cjs
175180
- name: Test
176-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 sls-esbuild-cjs.test.ts
181+
run: npx vitest --retry 1 sls-esbuild-cjs.test.ts
177182
working-directory: test
178183
- name: Test - observable mode
179-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 sls-esbuild-cjs.test.ts
184+
run: OBSERVABLE_MODE=true npx vitest --retry 1 sls-esbuild-cjs.test.ts
180185
working-directory: test
181186

182187
test-sls-esbuild-esm:
@@ -188,7 +193,7 @@ jobs:
188193
- name: Use Node.js
189194
uses: actions/setup-node@v4
190195
with:
191-
node-version: "20"
196+
node-version: ${{ env.node_version }}
192197
registry-url: "https://registry.npmjs.org"
193198
- name: Move vite.config.ts to test folder
194199
run: |
@@ -229,10 +234,10 @@ jobs:
229234
run: npm run deploy
230235
working-directory: test/sls-esbuild-esm
231236
- name: Test
232-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 sls-esbuild-esm.test.ts
237+
run: npx vitest --retry 1 sls-esbuild-esm.test.ts
233238
working-directory: test
234239
- name: Test - observable mode
235-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 sls-esbuild-esm.test.ts
240+
run: OBSERVABLE_MODE=true npx vitest --retry 1 sls-esbuild-esm.test.ts
236241
working-directory: test
237242

238243
test-sam-basic:
@@ -248,7 +253,7 @@ jobs:
248253
- name: Use Node.js
249254
uses: actions/setup-node@v4
250255
with:
251-
node-version: "20"
256+
node-version: ${{ env.node_version }}
252257
registry-url: "https://registry.npmjs.org"
253258
- name: Move vite.config.ts to test folder
254259
run: |
@@ -289,10 +294,10 @@ jobs:
289294
run: npm run deploy
290295
working-directory: test/sam-basic
291296
- name: Test
292-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 sam-basic.test.ts
297+
run: npx vitest --retry 1 sam-basic.test.ts
293298
working-directory: test
294299
- name: Test - observable mode
295-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 sam-basic.test.ts
300+
run: OBSERVABLE_MODE=true npx vitest --retry 1 sam-basic.test.ts
296301
working-directory: test
297302

298303
test-terraform-basic:
@@ -304,7 +309,7 @@ jobs:
304309
- name: Use Node.js
305310
uses: actions/setup-node@v4
306311
with:
307-
node-version: "20"
312+
node-version: ${{ env.node_version }}
308313
registry-url: "https://registry.npmjs.org"
309314
- name: Move vite.config.ts to test folder
310315
run: |
@@ -351,8 +356,8 @@ jobs:
351356
run: npm run deploy
352357
working-directory: test/terraform-basic
353358
- name: Test
354-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true npx vitest --retry 1 terraform-basic.test.ts
359+
run: npx vitest --retry 1 terraform-basic.test.ts
355360
working-directory: test
356361
- name: Test - observable mode
357-
run: REAL_NPM=true DISABLE_PARALLEL_DEPLOY=true OBSERVABLE_MODE=true npx vitest --retry 1 terraform-basic.test.ts
362+
run: OBSERVABLE_MODE=true npx vitest --retry 1 terraform-basic.test.ts
358363
working-directory: test

test/cdk-basic/services/testJsCommonJs/lambda.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ const lambdaHandler = async (event, context) => {
2323
const fs = require("fs");
2424
const path = require("path");
2525
const filePath = path.join(
26-
process.env.LOCAL_PROJECT_DIR,
2726
"..",
2827
"local_lambda_responses",
2928
`${context.functionName}.json`

test/cdk-basic/services/testJsEsModule/lambda.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ export const lambdaHandler = async (event, context) => {
2323
const fs = await import("fs");
2424
const path = await import("path");
2525
const filePath = path.join(
26-
process.env.LOCAL_PROJECT_DIR,
2726
"..",
2827
"local_lambda_responses",
2928
`${context.functionName}.json`

test/cdk-basic/services/testTsCommonJs/lambda.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ export const lambdaHandler: Handler = async (event, context) => {
2424
const fs = await import("fs");
2525
const path = await import("path");
2626
const filePath = path.join(
27-
process.env.LOCAL_PROJECT_DIR!,
2827
"..",
2928
"local_lambda_responses",
3029
`${context.functionName}.json`

test/cdk-basic/services/testTsEsModule/lambda.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ export const lambdaHandler: Handler = async (event, context) => {
2424
const fs = await import("fs");
2525
const path = await import("path");
2626
const filePath = path.join(
27-
process.env.LOCAL_PROJECT_DIR!,
2827
"..",
2928
"local_lambda_responses",
3029
`${context.functionName}.json`

test/cdk-config/services/testJsCommonJs/lambda.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ const lambdaHandler = async (event, context) => {
2323
const fs = require("fs");
2424
const path = require("path");
2525
const filePath = path.join(
26-
process.env.LOCAL_PROJECT_DIR,
2726
"..",
2827
"local_lambda_responses",
2928
`${context.functionName}.json`

test/cdk-config/services/testJsEsModule/lambda.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ export const lambdaHandler = async (event, context) => {
2323
const fs = await import("fs");
2424
const path = await import("path");
2525
const filePath = path.join(
26-
process.env.LOCAL_PROJECT_DIR,
2726
"..",
2827
"local_lambda_responses",
2928
`${context.functionName}.json`

test/cdk-config/services/testTsCommonJs/lambda.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ export const lambdaHandler: Handler = async (event, context) => {
2424
const fs = await import("fs");
2525
const path = await import("path");
2626
const filePath = path.join(
27-
process.env.LOCAL_PROJECT_DIR!,
2827
"..",
2928
"local_lambda_responses",
3029
`${context.functionName}.json`

test/cdk-config/services/testTsEsModule/lambda.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ export const lambdaHandler: Handler = async (event, context) => {
2424
const fs = await import("fs");
2525
const path = await import("path");
2626
const filePath = path.join(
27-
process.env.LOCAL_PROJECT_DIR!,
2827
"..",
2928
"local_lambda_responses",
3029
`${context.functionName}.json`

test/cdk-config/services_alternative/testJsCommonJs/lambda.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ const lambdaHandler = async (event, context) => {
2323
const fs = require("fs");
2424
const path = require("path");
2525
const filePath = path.join(
26-
process.env.LOCAL_PROJECT_DIR,
2726
"..",
2827
"local_lambda_responses",
2928
`${context.functionName}.json`

0 commit comments

Comments
 (0)