Skip to content
Merged
Show file tree
Hide file tree
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
23 changes: 23 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,26 @@ updates:
commit-message:
prefix: "ci"
include: "scope"

# Enable version updates for the fli-js (npm) package
- package-ecosystem: "npm"
directory: "/fli-js"
schedule:
interval: "weekly"
day: "monday"
open-pull-requests-limit: 5
reviewers:
- "punitarani"
commit-message:
prefix: "deps"
include: "scope"
groups:
js-dev-dependencies:
patterns:
- "@biomejs/*"
- "@types/*"
- "oxlint"
- "typescript"
js-production-dependencies:
patterns:
- "zod"
30 changes: 0 additions & 30 deletions .github/workflows/actionlint.yml

This file was deleted.

148 changes: 141 additions & 7 deletions .github/workflows/test.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Run Tests
name: CI

on:
push:
Expand All @@ -13,14 +13,147 @@ on:
required: false
type: string

permissions:
contents: read
checks: write
pull-requests: write

jobs:
changes:
name: Detect changes
runs-on: ubuntu-latest
outputs:
fli-js: ${{ steps.filter.outputs.fli-js || 'true' }}
workflows: ${{ steps.filter.outputs.workflows || 'true' }}
steps:
- uses: actions/checkout@v6

- uses: dorny/paths-filter@v3
id: filter
if: github.event_name == 'pull_request'
with:
filters: |
fli-js:
- 'fli-js/**'
- 'data/**'
- '.github/workflows/ci.yml'
workflows:
- '.github/workflows/**'
- '.github/actionlint.yaml'

actionlint:
name: Actionlint
needs: changes
if: needs.changes.outputs.workflows == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- name: Run actionlint
uses: raven-actions/actionlint@v2
with:
# Show inline annotations on the PR diff for any findings
matcher: true

lint:
uses: ./.github/workflows/lint.yml
name: Lint Python
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6

- name: Install uv
uses: astral-sh/setup-uv@v7
with:
version: "latest"

- name: Set up Python
run: uv python install 3.10

- name: Install dependencies
run: uv sync --extra dev

- name: Check formatting
run: uv run ruff format . --check

- name: Check style
run: uv run ruff check .

fli-js-lint:
name: fli-js / Format & lint
needs: changes
if: needs.changes.outputs.fli-js == 'true'
runs-on: ubuntu-latest
defaults:
run:
working-directory: fli-js
steps:
- uses: actions/checkout@v6

- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Biome format check
run: bun run format:check

- name: Biome + oxlint check
run: bun run lint

- name: TypeScript typecheck
run: bun run typecheck

fli-js-test:
name: fli-js / Bun tests
needs: [ changes, fli-js-lint ]
if: needs.changes.outputs.fli-js == 'true'
runs-on: ubuntu-latest
defaults:
run:
working-directory: fli-js
steps:
- uses: actions/checkout@v6

- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest

- name: Install dependencies
run: bun install --frozen-lockfile

- name: Verify generated enums are in sync with data/
run: |
bun run generate:enums
if ! git diff --quiet src/models/airport.ts src/models/airline.ts; then
echo "Generated enums are out of date — run 'bun run generate:enums' and commit." >&2
git diff --stat src/models/airport.ts src/models/airline.ts
exit 1
fi

- name: Run tests with coverage
run: bun run test:ci

- name: Upload fli-js test results
if: always() && !env.ACT
uses: actions/upload-artifact@v7
with:
name: Test Results (fli-js)
path: fli-js/junit.xml

- name: Upload fli-js coverage
if: always() && !env.ACT
uses: actions/upload-artifact@v7
with:
name: Coverage (fli-js)
path: fli-js/coverage/

railway-build:
name: Railway build validation
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v6
with:
Expand Down Expand Up @@ -88,6 +221,7 @@ jobs:
python -c "import fastmcp, fli.mcp.server"

test:
name: test
needs: [ lint, railway-build ]
runs-on: ubuntu-latest
strategy:
Expand Down Expand Up @@ -128,14 +262,14 @@ jobs:
path: junit.xml

publish-test-results:
name: "Publish Test Results"
needs: [ railway-build, test ]
name: Publish Test Results
needs: [ test, fli-js-test ]
runs-on: ubuntu-latest
if: always() && needs.test.result != 'skipped'
if: always() && (needs.test.result != 'skipped' || needs.fli-js-test.result != 'skipped')
permissions:
checks: write
pull-requests: write

steps:
- name: Download Artifacts
uses: actions/download-artifact@v8
Expand Down
32 changes: 0 additions & 32 deletions .github/workflows/lint.yml

This file was deleted.

Loading
Loading