Skip to content

fix(generator): all 54 specs compile (gitea Swagger 2.0 skipped) #50

fix(generator): all 54 specs compile (gitea Swagger 2.0 skipped)

fix(generator): all 54 specs compile (gitea Swagger 2.0 skipped) #50

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
CARGO_TERM_COLOR: always
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: cargo test --all-features
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
- run: cargo clippy --all-features -- -D warnings
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- run: cargo fmt --check
doc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: cargo doc --no-deps --all-features
env:
RUSTDOCFLAGS: -D warnings
# Regression guard: generate clients for our two production-target specs
# (OpenAI + Anthropic) and `cargo check` the result. Catches breakage
# where a generator change still passes unit tests but emits invalid
# Rust against the specs we actually ship clients for.
#
# The full corpus (54 specs) is verified locally via
# `scripts/spec-compile.sh` (no args) — but cargo-checking 50+
# generated crates exceeded CI's 6-hour job limit on the largest
# specs (microsoft-graph, cloudflare). Local + this CI gate is
# sufficient: regressions to anthropic/openai will fail PRs, and
# contributors can run the full corpus before pushing.
spec-compile:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: scripts/spec-compile.sh anthropic openai