Consolidate cache-dependency-path e2e workflow and add maven/sbt coverage#1124
Merged
Merged
Conversation
Fold the standalone 'Validate cache with cache-dependency-path option' workflow into e2e-cache.yml and delete the separate file. The three gradle1-save/gradle1-restore/gradle2-restore jobs are copied verbatim, preserving their matrix, cache-dependency-path inputs, and needs relationships. No change in test coverage. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 635b89fa-5c35-49e1-a257-dc9001ebb8db
Contributor
There was a problem hiding this comment.
Pull request overview
This PR consolidates the cache cache-dependency-path end-to-end validation into the existing e2e-cache.yml workflow by moving the three Gradle dependency-path jobs into it and deleting the now-redundant standalone workflow file.
Changes:
- Added the
gradle1-save,gradle1-restore, andgradle2-restorejobs (including their matrix andneeds:relationships) to.github/workflows/e2e-cache.yml. - Removed
.github/workflows/e2e-cache-dependency-path.ymlentirely to avoid duplicate workflow definitions.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/e2e-cache.yml | Appends the three cache-dependency-path Gradle jobs to the existing cache E2E workflow. |
| .github/workflows/e2e-cache-dependency-path.yml | Deletes the redundant standalone workflow after consolidating its jobs into e2e-cache.yml. |
Review details
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 0
- Review effort level: Low
Previously only gradle exercised the cache-dependency-path input. Mirror the gradle save/restore(hit)/restore(miss) pattern for maven and sbt: - maven1-save/maven1-restore/maven2-restore - sbt1-save/sbt1-restore/sbt2-restore Each save+restore pair uses the same cache-dependency-path so the restore is a hit, while the second restore points at a new maven2/sbt2 fixture whose different dependencies produce a different hash, so the cache is a miss (directory not created). New fixtures added under __tests__/cache. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 635b89fa-5c35-49e1-a257-dc9001ebb8db
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Consolidates the e2e cache workflows and extends
cache-dependency-pathcoverage.1. Merge the standalone dependency-path workflow
The standalone
e2e-cache-dependency-path.yml("Validate cache with cache-dependency-path option") overlapped heavily withe2e-cache.yml("Validate cache"). Its three gradle jobs (gradle1-save,gradle1-restore,gradle2-restore) were copied verbatim intoe2e-cache.yml— same matrix (macos-latest, windows-latest, ubuntu-latest),cache-dependency-pathinputs, andneeds:relationships (both restores depend ongradle1-save) — and the standalone file was deleted. No coverage change from this step.2. Close the gap: cache-dependency-path for maven and sbt
Previously
cache-dependency-pathwas only exercised for gradle. This PR adds the same three-job pattern for maven and sbt:maven1-save→maven1-restore(cache hit) /maven2-restore(cache miss)sbt1-save→sbt1-restore(cache hit) /sbt2-restore(cache miss)Each save + restore pair uses the same
cache-dependency-path, so the restore is a hit. The second restore points at a new__tests__/cache/maven2/__tests__/cache/sbt2fixture whose different dependencies hash to a different cache key, so the cache is a miss and the tool's cache directory is not created — mirroringgradle2-restoreexactly.New fixtures:
__tests__/cache/maven2/pom.xml(+.gitignore) —commons-lang3instead ofjunit-jupiter-api__tests__/cache/sbt2/build.sbt(+.gitignore) — differentscala-parser-combinatorsversionThe maven/sbt dependency-path jobs reuse each tool's existing matrix and setup (maven on
macos-15-intel; sbt onmacos-15-intel/ubuntu-22.04withbrew install sbton macOS and OS-specific Coursier cache checks), so they are not affected by gradle'smacos-latest.Validation
python3+yaml.safe_load; all 15 job names are unique.needs:verified for every restore job.