Skip to content

release: Feature Freeze for Audit #302

release: Feature Freeze for Audit

release: Feature Freeze for Audit #302

name: TypeScript Integration Tests
on:
workflow_dispatch:
workflow_call:
push:
branches: [main, "release/*"]
paths:
# TS SDK changes
- "sdks/ts/**"
# Backend changes that affect TS integration
- "crates/**"
- "tests/**"
- "Cargo.*"
- "Makefile"
- "makefiles/**"
- ".github/workflows/typescript-integration.yml"
- ".github/workflows/build-rust.yml"
- ".github/actions/run-test-runner/**"
pull_request:
branches: [main, "release/*"]
paths:
# TS SDK changes
- "sdks/ts/**"
# Backend changes that affect TS integration
- "crates/**"
- "tests/**"
- "Cargo.*"
- "Makefile"
- "makefiles/**"
- ".github/workflows/typescript-integration.yml"
- ".github/workflows/build-rust.yml"
- ".github/actions/run-test-runner/**"
env:
CARGO_TERM_COLOR: always
RUST_LOG: info
jobs:
build:
name: Build Rust Backend
uses: ./.github/workflows/build-rust.yml
with:
cache-key: "typescript-integration-build"
artifact-name: "rust-binaries-ts"
typescript-integration:
name: TypeScript SDK Integration Tests
runs-on: ubuntu-latest
needs: build
timeout-minutes: 30
strategy:
fail-fast: false
matrix:
test-group: [typescript_basic, typescript_auth]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
with:
shared-key: "typescript-integration-${{ matrix.test-group }}"
- name: Download build artifacts
uses: actions/download-artifact@v4
with:
name: ${{ needs.build.outputs.artifact-name }}
path: target/debug/
- name: Make binaries executable
run: chmod +x target/debug/kora target/debug/test_runner
- name: Setup Solana CLI
uses: ./.github/actions/setup-solana
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "lts/*"
- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: 10.12.3
run_install: false
- name: Get pnpm store directory
shell: bash
run: echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Setup pnpm cache
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('sdks/ts/pnpm-lock.yaml') }}
restore-keys: ${{ runner.os }}-pnpm-store-
- name: Install TypeScript dependencies
working-directory: sdks/ts
run: pnpm install --frozen-lockfile
- name: Build TypeScript SDK
working-directory: sdks/ts
run: pnpm build
- name: Run TypeScript integration tests
uses: ./.github/actions/run-test-runner
with:
filters: "--filter ${{ matrix.test-group }}"
- name: Cleanup test environment
if: always()
uses: ./.github/actions/cleanup-test-env
- name: Show failure logs
if: failure()
uses: ./.github/actions/show-failure-logs
with:
test-type: "TypeScript integration (${{ matrix.test-group }})"