Skip to content

Commit ae6fc3b

Browse files
committed
add tests github workflow
1 parent 88b33d3 commit ae6fc3b

File tree

8 files changed

+56
-80
lines changed

8 files changed

+56
-80
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: 'Setup Node.js and pnpm'
2+
description: 'Installs Node.js, pnpm, and dependencies'
3+
runs:
4+
using: "composite"
5+
steps:
6+
7+
- name: Install pnpm
8+
uses: pnpm/action-setup@v4
9+
with:
10+
run_install: false
11+
12+
- name: Setup pnpm cache
13+
uses: actions/cache@v4
14+
with:
15+
path: /home/runner/setup-pnpm/node_modules/.bin/store/v3
16+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
17+
restore-keys: ${{ runner.os }}-pnpm-store-
18+
19+
- name: Install dependencies
20+
shell: bash
21+
run: pnpm install --frozen-lockfile --prefer-offline

β€Ž.github/workflows/deploy.yamlβ€Ž

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ on:
66
- master
77
- staging
88
permissions:
9-
id-token: write # This is required for requesting the JWT
10-
contents: read # This is required for actions/checkout
9+
id-token: write # This is required for requesting the JWT
10+
contents: read # This is required for actions/checkout
1111
jobs:
1212
deploy:
13-
runs-on: ubuntu-latest
13+
runs-on: ubuntu-24.04
1414
steps:
1515
- name: Checkout Repository
1616
uses: actions/checkout@v4

β€Ž.github/workflows/release-prod.yamlβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ permissions:
88
jobs:
99
create_release_notes:
1010
if: github.ref_type == 'branch' && github.ref_name == 'master'
11-
runs-on: ubuntu-latest
11+
runs-on: ubuntu-24.04
1212
steps:
1313
- name: Checkout Repository
1414
uses: actions/checkout@v4

β€Ž.github/workflows/remove.yamlβ€Ž

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ name: Remove Deployment
22
on:
33
workflow_dispatch:
44
permissions:
5-
id-token: write # This is required for requesting the JWT
6-
contents: read # This is required for actions/checkout
5+
id-token: write # This is required for requesting the JWT
6+
contents: read # This is required for actions/checkout
77
jobs:
88
deploy:
99
# We don't want to remove protected deployment
1010
if: github.ref_protected == false
11-
runs-on: ubuntu-latest
11+
runs-on: ubuntu-24.04
1212
steps:
1313
- name: Checkout Repository
1414
uses: actions/checkout@v4

β€Ž.github/workflows/test.yamlβ€Ž

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Test Branch
2+
on:
3+
workflow_dispatch:
4+
push:
5+
6+
permissions:
7+
id-token: write # This is required for requesting the JWT
8+
contents: read # This is required for actions/checkout
9+
jobs:
10+
test:
11+
runs-on: ubuntu-24.04
12+
steps:
13+
- name: Checkout Repository
14+
uses: actions/checkout@v4
15+
16+
- name: Setup Node.js and pnpm
17+
uses: "./.github/actions/setup_node_and_pnpm"
18+
19+
- name: Code Lint
20+
run: pnpm run lint
21+
22+
- name: Code Lint
23+
run: pnpm run typecheck
24+
25+
- name: Code Lint
26+
run: pnpm run test

β€Ž.github/workflows/test.yaml.bakβ€Ž

Lines changed: 0 additions & 72 deletions
This file was deleted.

β€Žmise.tomlβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tools]
22
nodejs = '22.19.0'
3-
pnpm = '10.17.0'
3+
pnpm = '10.18.2'
44
[env]
55
AWS_REGION = 'eu-central-1'
66
_.source = 'scripts/set_sst_stage.sh'

β€Žpackage.jsonβ€Ž

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "purple-stack",
33
"version": "4.0.0",
4+
"packageManager": "pnpm@10.18.2",
45
"scripts": {
56
"lint": "biome check",
67
"lint:fix": "biome check --fix",

0 commit comments

Comments
Β (0)