Files
copilotkit__copilotkit/.github/workflows/test_unit.yml
Alem Tuzlak 9a6ee39d96 chore(runtime): update package config, CI workflows, and docs
- Add package.json exports for v2/{express,hono,node} subpaths
- Add elysia devDependency and tsdown entry points
- Exclude bun integration tests from vitest config
- Update CI workflows to include runtime-servers test job
- Add runtime-server-adapter docs page
- Add changeset for the fetch-based runtime feature
2026-04-03 18:41:27 +02:00

77 lines
2.0 KiB
YAML

name: test / unit
on:
push:
branches: [main]
paths-ignore:
- "docs/**"
- "README.md"
- "examples/**"
- ".github/workflows/demos_preview.yml"
- ".github/workflows/release.yml"
- "packages/**/package.json"
- "packages/**/CHANGELOG.md"
- ".changeset/**"
pull_request:
branches: [main]
paths-ignore:
- "docs/**"
- "README.md"
- "examples/**"
workflow_dispatch:
inputs:
branch:
description: "Branch to run the workflow on"
required: true
default: "main"
type: string
env:
NODE_OPTIONS: "--max-old-space-size=4096"
NX_VERBOSE_LOGGING: true
NX_CI_EXECUTION_ID: ${{ github.head_ref }}-${{ github.sha }}-${{ github.run_attempt }}
NX_CI_EXECUTION_ENV: "Unit Tests"
jobs:
unit:
name: "unit"
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
fail-fast: false
matrix:
node-version: [20.x, 22.x, 24.x]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.event.inputs.branch || github.ref }}
- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: "10.13.1"
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Configure Nx Cloud environment
run: |
echo "NX_CI_EXECUTION_ID=${{ github.run_id }}-${{ github.run_attempt }}-unit-v1-${{ matrix.node-version }}" >> $GITHUB_ENV
echo "NX_CLOUD_NO_TIMEOUTS=true" >> $GITHUB_ENV
echo "NX_CLOUD_DISTRIBUTED_EXECUTION=false" >> $GITHUB_ENV
echo "NX_NO_CLOUD=true" >> $GITHUB_ENV
- name: Generate GraphQL codegen files
run: npx nx run @copilotkit/runtime-client-gql:graphql-codegen
- name: Build
run: pnpm run build
- name: Run tests
run: pnpm run test