Skip to content

Commit 245e1e3

Browse files
authored
Create chapter-api-tests.yml
1 parent d6c869e commit 245e1e3

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/chapter-api-tests.yml

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: "🧪 API Tests"
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
apiTests:
8+
name: "🧪 API Tests"
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: ⬇️ Checkout repo
12+
uses: actions/checkout@v4
13+
with:
14+
fetch-depth: 0
15+
16+
- name: ⎔ Setup pnpm
17+
uses: pnpm/action-setup@v4
18+
with:
19+
version: 8.15.5
20+
21+
- name: ⎔ Setup node
22+
uses: buildjet/setup-node@v4
23+
with:
24+
node-version: 20.11.1
25+
cache: "pnpm"
26+
27+
- name: 📥 Download deps
28+
run: pnpm install --frozen-lockfile
29+
30+
- name: 📀 Generate Prisma Client
31+
run: pnpm run generate
32+
33+
- name: 🧪 Run Webapp API Tests
34+
run: pnpm run test chapter_api_tests/
35+
env:
36+
DATABASE_URL: postgresql://postgres:postgres@localhost:5432/postgres
37+
DIRECT_URL: postgresql://postgres:postgres@localhost:5432/postgres
38+
SESSION_SECRET: "secret"
39+
MAGIC_LINK_SECRET: "secret"
40+
ENCRYPTION_KEY: "secret"

0 commit comments

Comments
 (0)