Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 8 additions & 47 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,76 +3,47 @@ name: TrustSignal CI
on:
push:
branches:
- work
- master
pull_request:
branches:
- work
- master

jobs:
lint:
runs-on: ubuntu-latest
env:
DATABASE_URL: ${{ secrets.DATABASE_URL }}
TRUSTSIGNAL_JWT_SECRET: ${{ secrets.TRUSTSIGNAL_JWT_SECRET }}
TRUSTSIGNAL_JWT_SECRETS: ${{ secrets.TRUSTSIGNAL_JWT_SECRETS }}
POLYGON_RPC_URL: ${{ secrets.POLYGON_RPC_URL }}
steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
run: npm ci

- name: Run lint
run: |
npx eslint --no-ignore \
src/middleware/auth.ts \
src/middleware/logger.ts \
src/middleware/rateLimit.ts \
src/routes/app.ts \
src/routes/dependencies.ts \
src/routes/revoke.ts \
src/routes/status.ts \
src/routes/verify.ts \
src/core/verifyBundle.ts \
tests/api/routes.test.ts \
tests/integration/fullBundle.test.ts \
tests/middleware/auth.test.ts \
tests/middleware/logger.test.ts \
tests/middleware/rateLimit.test.ts \
tests/adversarial/zkml_adversarial.test.ts \
vitest.config.ts
run: npm run lint

typecheck:
runs-on: ubuntu-latest
env:
DATABASE_URL: ${{ secrets.DATABASE_URL }}
TRUSTSIGNAL_JWT_SECRET: ${{ secrets.TRUSTSIGNAL_JWT_SECRET }}
TRUSTSIGNAL_JWT_SECRETS: ${{ secrets.TRUSTSIGNAL_JWT_SECRETS }}
POLYGON_RPC_URL: ${{ secrets.POLYGON_RPC_URL }}
steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
run: npm ci

- name: Type check
run: npx tsc --strict --noEmit
run: npm run typecheck

test:
runs-on: ubuntu-latest
Expand All @@ -88,7 +59,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
Expand All @@ -99,19 +70,14 @@ jobs:

web-build:
runs-on: ubuntu-latest
env:
DATABASE_URL: ${{ secrets.DATABASE_URL }}
TRUSTSIGNAL_JWT_SECRET: ${{ secrets.TRUSTSIGNAL_JWT_SECRET }}
TRUSTSIGNAL_JWT_SECRETS: ${{ secrets.TRUSTSIGNAL_JWT_SECRETS }}
POLYGON_RPC_URL: ${{ secrets.POLYGON_RPC_URL }}
steps:
- name: Checkout
uses: actions/checkout@v6

- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
Expand Down Expand Up @@ -145,7 +111,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
Expand All @@ -156,11 +122,6 @@ jobs:

rust-build:
runs-on: ubuntu-latest
env:
DATABASE_URL: ${{ secrets.DATABASE_URL }}
TRUSTSIGNAL_JWT_SECRET: ${{ secrets.TRUSTSIGNAL_JWT_SECRET }}
TRUSTSIGNAL_JWT_SECRETS: ${{ secrets.TRUSTSIGNAL_JWT_SECRETS }}
POLYGON_RPC_URL: ${{ secrets.POLYGON_RPC_URL }}
defaults:
run:
working-directory: circuits/non_mem_gadget
Expand Down Expand Up @@ -202,7 +163,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 22
node-version: '20'
cache: npm

- name: Install dependencies
Expand Down
Loading