From e0d6bfbdd13f6a324eb5d29eaf1810dc377fd38e Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 28 May 2026 16:51:48 +0000 Subject: [PATCH 1/5] Add CI workflow to run clippy and tests on all PRs Also remove the orphaned tests/openapi.rs, which referenced the openapi module deleted in 9f64cc1 and broke `cargo test --all-features`. https://claude.ai/code/session_01BzqC31UjuAPBM2H7hfzdju --- .github/workflows/pr.yaml | 28 ++++++++++++++++++++++++++++ tests/openapi.rs | 7 ------- 2 files changed, 28 insertions(+), 7 deletions(-) create mode 100644 .github/workflows/pr.yaml delete mode 100644 tests/openapi.rs diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml new file mode 100644 index 0000000..46ce2cd --- /dev/null +++ b/.github/workflows/pr.yaml @@ -0,0 +1,28 @@ +name: CI + +on: + pull_request: + +jobs: + test: + name: ๐Ÿงช Test and Lint + runs-on: ubuntu-latest + steps: + - name: ๐Ÿ›  Checkout + uses: actions/checkout@v4 + + - name: ๐Ÿ“ฆ Cargo clippy (default features) + run: | + cargo clippy -- -D warnings + + - name: ๐Ÿ“ฆ Cargo clippy (all features) + run: | + cargo clippy --all-features -- -D warnings + + - name: ๐Ÿงช Cargo test (default features) + run: | + cargo test + + - name: ๐Ÿงช Cargo test (all features) + run: | + cargo test --all-features diff --git a/tests/openapi.rs b/tests/openapi.rs deleted file mode 100644 index 9a49d97..0000000 --- a/tests/openapi.rs +++ /dev/null @@ -1,7 +0,0 @@ -#[cfg(feature = "utoipa")] -#[test] -fn test_openapi() { - use utoipa::OpenApi; - let openapi = platz_chart_ext::openapi::OpenApi::openapi(); - println!("{}", openapi.to_json().unwrap()); -} From ba38987f9088cb88fc0b9a6a20ca01afd0b9224c Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 28 May 2026 16:57:14 +0000 Subject: [PATCH 2/5] Test full feature powerset via reusable cargo-hack workflow Extract clippy + test into a reusable test.yml that runs the cargo-hack feature powerset (no features, all features, and every subset). Both the PR workflow and the release workflow now call it, so releases run the same checks before publishing. https://claude.ai/code/session_01BzqC31UjuAPBM2H7hfzdju --- .github/workflows/pr.yaml | 22 +--------------------- .github/workflows/release.yml | 22 +++++----------------- .github/workflows/test.yml | 25 +++++++++++++++++++++++++ 3 files changed, 31 insertions(+), 38 deletions(-) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 46ce2cd..4d6fc63 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -5,24 +5,4 @@ on: jobs: test: - name: ๐Ÿงช Test and Lint - runs-on: ubuntu-latest - steps: - - name: ๐Ÿ›  Checkout - uses: actions/checkout@v4 - - - name: ๐Ÿ“ฆ Cargo clippy (default features) - run: | - cargo clippy -- -D warnings - - - name: ๐Ÿ“ฆ Cargo clippy (all features) - run: | - cargo clippy --all-features -- -D warnings - - - name: ๐Ÿงช Cargo test (default features) - run: | - cargo test - - - name: ๐Ÿงช Cargo test (all features) - run: | - cargo test --all-features + uses: ./.github/workflows/test.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4c93afb..b731b2c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,29 +6,17 @@ on: - v** jobs: - build: + test: + uses: ./.github/workflows/test.yml + + publish: name: ๐Ÿš€ Publish to crates.io + needs: test runs-on: ubuntu-latest steps: - name: ๐Ÿ›  Checkout uses: actions/checkout@v4 - - name: ๐Ÿ“ฆ Cargo clippy (default features) - run: | - cargo clippy -- -D warnings - - - name: ๐Ÿ“ฆ Cargo clippy (all features) - run: | - cargo clippy --all-features -- -D warnings - - - name: ๐Ÿ“ฆ Cargo build (default features) - run: | - cargo build --release - - - name: ๐Ÿ“ฆ Cargo build (all features) - run: | - cargo build --release --all-features - - name: ๐Ÿš€ Publish Crate env: CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }} diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..93d8c99 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,25 @@ +name: Test and Lint + +on: + workflow_call: + +jobs: + test: + name: ๐Ÿงช Test and Lint + runs-on: ubuntu-latest + steps: + - name: ๐Ÿ›  Checkout + uses: actions/checkout@v4 + + - name: ๐Ÿ”ง Install cargo-hack + uses: taiki-e/install-action@v2 + with: + tool: cargo-hack + + - name: ๐Ÿ“ฆ Cargo clippy (feature powerset) + run: | + cargo hack clippy --feature-powerset -- -D warnings + + - name: ๐Ÿงช Cargo test (feature powerset) + run: | + cargo hack test --feature-powerset From 65e66d9aff1f612f57ffa166b40ec088012557bf Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 28 May 2026 17:03:43 +0000 Subject: [PATCH 3/5] Run feature powerset across both debug and release profiles Add a profile matrix (debug/release) to the reusable test workflow so clippy and tests cover every feature subset in both build profiles. https://claude.ai/code/session_01BzqC31UjuAPBM2H7hfzdju --- .github/workflows/test.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 93d8c99..6f299fd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,8 +5,14 @@ on: jobs: test: - name: ๐Ÿงช Test and Lint + name: ๐Ÿงช Test and Lint (${{ matrix.profile }}) runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + profile: + - debug + - release steps: - name: ๐Ÿ›  Checkout uses: actions/checkout@v4 @@ -18,8 +24,8 @@ jobs: - name: ๐Ÿ“ฆ Cargo clippy (feature powerset) run: | - cargo hack clippy --feature-powerset -- -D warnings + cargo hack clippy --feature-powerset ${{ matrix.profile == 'release' && '--release' || '' }} -- -D warnings - name: ๐Ÿงช Cargo test (feature powerset) run: | - cargo hack test --feature-powerset + cargo hack test --feature-powerset ${{ matrix.profile == 'release' && '--release' || '' }} From 4a4fed1a1c6551f5fc6b0392088094c416cc8d31 Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 28 May 2026 17:04:59 +0000 Subject: [PATCH 4/5] Trigger test workflow directly on pull_request Drop the separate pr.yaml wrapper and add the pull_request trigger to the reusable test workflow, which still exposes workflow_call for releases. https://claude.ai/code/session_01BzqC31UjuAPBM2H7hfzdju --- .github/workflows/pr.yaml | 8 -------- .github/workflows/test.yml | 1 + 2 files changed, 1 insertion(+), 8 deletions(-) delete mode 100644 .github/workflows/pr.yaml diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml deleted file mode 100644 index 4d6fc63..0000000 --- a/.github/workflows/pr.yaml +++ /dev/null @@ -1,8 +0,0 @@ -name: CI - -on: - pull_request: - -jobs: - test: - uses: ./.github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6f299fd..af4e884 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,6 +1,7 @@ name: Test and Lint on: + pull_request: workflow_call: jobs: From 10c976ab601821db6ee417b9e713c70ca6283e3a Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 28 May 2026 17:07:00 +0000 Subject: [PATCH 5/5] Rename test workflow to "Test" and add emojis to workflow names https://claude.ai/code/session_01BzqC31UjuAPBM2H7hfzdju --- .github/workflows/release.yml | 2 +- .github/workflows/test.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b731b2c..95dd91e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -name: Publish to crates.io +name: ๐Ÿš€ Publish to crates.io on: push: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index af4e884..7d442fd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,4 +1,4 @@ -name: Test and Lint +name: ๐Ÿงช Test on: pull_request: @@ -6,7 +6,7 @@ on: jobs: test: - name: ๐Ÿงช Test and Lint (${{ matrix.profile }}) + name: ๐Ÿงช Test (${{ matrix.profile }}) runs-on: ubuntu-latest strategy: fail-fast: false