Add Windows coverage for caching via a new smoke-test suite (#1027)

## Why

Issue #1013 revealed that caching was **never storing content on
Windows**. Nothing caught it because the integ-tests lost their multi-OS
matrices: these workflows used to default to `'["ubuntu-latest",
"windows-latest", "macos-latest"]'`, narrowed to ubuntu-only in bcd07e66
/ d74ee73e (Aug 2024). The Windows code path has been dark ever since.

## What

Extract the two cheapest caching tests — `restore-gradle-home` and
`basic-cache-provider` — into a new `suite-smoke-test-caching` workflow,
and run that suite on both `ubuntu-latest` and `windows-latest`.

Both tests seed a cache in one job and then verify it in a dependent job
with an `--offline` build, so a cache that stores nothing fails the
verify job rather than passing silently.

- Rename `integ-test-{restore-gradle-home,basic-cache-provider}` →
`smoke-test-*` and drop them from `suite-integ-test-caching`
- Add the new suite to both `CI-integ-test` and `CI-integ-test-full`,
each with its own concurrency group matching the sibling suites
- Include `smoke-tests` in the `integ-test-success` aggregate gate
- Ignore the generated `task-configured.txt` marker in
`workflow-samples`
- Drop a dead `needs.determine-suite` guard on the `build-distribution`
step — `CI-integ-test` has no such job, so it always evaluated to true

The suite runs on Windows in PR CI (not just `CI-integ-test-full`)
specifically so the failure is visible on this PR and the fix can be
verified the same way.

## Expected result

This PR is expected to be **red on Windows**.
`restore-gradle-home-dependencies-cache` and `basic-cache-verify-build`
should fail with dependency-resolution errors under `--offline` — that
is the bug from #1013 being caught. The ubuntu legs should stay green.

Cross-OS cache keys are safe: both providers include `RUNNER_OS` in the
key (`sources/src/cache-service-basic.ts:146`), so the matrix legs don't
collide.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Daz DeBoer
2026-08-01 17:15:42 -06:00
committed by GitHub
co-authored by Claude Opus 5
parent 0088877924
commit 9d31058114
7 changed files with 53 additions and 12 deletions
+3
View File
@@ -3,3 +3,6 @@
# Ignore Gradle build output directory
build
# Marker file written when the 'test' task is configured
task-configured.txt
+10
View File
@@ -14,6 +14,16 @@ permissions:
contents: read
jobs:
smoke-tests:
uses: ./.github/workflows/suite-smoke-test-caching.yml
concurrency:
group: CI-smoke-test-caching
cancel-in-progress: false
with:
skip-dist: true
runner-os: '["ubuntu-latest", "windows-latest"]'
secrets: inherit
caching-integ-tests:
uses: ./.github/workflows/suite-integ-test-caching.yml
concurrency:
+13 -1
View File
@@ -21,9 +21,19 @@ jobs:
- name: Checkout sources
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
- name: Build and upload distribution
if: ${{ needs.determine-suite.outputs.suite != 'full' }}
uses: ./.github/actions/build-dist
smoke-tests:
needs: build-distribution
uses: ./.github/workflows/suite-smoke-test-caching.yml
concurrency:
group: CI-smoke-test-caching-${{ github.ref }}
cancel-in-progress: false
with:
skip-dist: false
runner-os: '["ubuntu-latest", "windows-latest"]'
secrets: inherit
caching-integ-tests:
needs: build-distribution
uses: ./.github/workflows/suite-integ-test-caching.yml
@@ -64,6 +74,7 @@ jobs:
if: ${{ always() }}
needs:
- build-distribution
- smoke-tests
- caching-integ-tests
- other-integ-tests
- dependency-submission-integ-tests
@@ -74,6 +85,7 @@ jobs:
run: |
echo "One or more integ-test jobs did not succeed:"
echo " build-distribution: ${{ needs.build-distribution.result }}"
echo " smoke-tests: ${{ needs.smoke-tests.result }}"
echo " caching-integ-tests: ${{ needs.caching-integ-tests.result }}"
echo " other-integ-tests: ${{ needs.other-integ-tests.result }}"
echo " dependency-submission-integ-tests: ${{ needs.dependency-submission-integ-tests.result }}"
@@ -36,11 +36,6 @@ jobs:
with:
skip-dist: ${{ inputs.skip-dist }}
restore-gradle-home:
uses: ./.github/workflows/integ-test-restore-gradle-home.yml
with:
skip-dist: ${{ inputs.skip-dist }}
restore-java-toolchain:
uses: ./.github/workflows/integ-test-restore-java-toolchain.yml
with:
@@ -57,9 +52,3 @@ jobs:
with:
runner-os: '${{ inputs.runner-os }}'
skip-dist: ${{ inputs.skip-dist }}
basic-cache-provider:
uses: ./.github/workflows/integ-test-basic-cache-provider.yml
with:
runner-os: '${{ inputs.runner-os }}'
skip-dist: ${{ inputs.skip-dist }}
@@ -0,0 +1,27 @@
name: suite-smoke-test-caching
on:
workflow_call:
inputs:
runner-os:
type: string
default: '["ubuntu-latest"]'
skip-dist:
type: boolean
default: false
permissions:
contents: read
jobs:
restore-gradle-home:
uses: ./.github/workflows/smoke-test-restore-gradle-home.yml
with:
runner-os: '${{ inputs.runner-os }}'
skip-dist: ${{ inputs.skip-dist }}
basic-cache-provider:
uses: ./.github/workflows/smoke-test-basic-cache-provider.yml
with:
runner-os: '${{ inputs.runner-os }}'
skip-dist: ${{ inputs.skip-dist }}