Skip to content

Add Gradle integration tests for Boot 4 migration version pinning#948

Closed
timtebeek wants to merge 2 commits intomainfrom
timtebeek/boot4-no-pin-starters
Closed

Add Gradle integration tests for Boot 4 migration version pinning#948
timtebeek wants to merge 2 commits intomainfrom
timtebeek/boot4-no-pin-starters

Conversation

@timtebeek
Copy link
Member

@timtebeek timtebeek commented Feb 26, 2026

Summary

  • Add UpgradeSpringBoot_4_0GradleTest with 4 integration tests verifying the Spring Boot 4 migration recipe handles Gradle dependency versions correctly

Context

Tests

  • doNotPinBomManagedStarters - literal plugin version + BOM-managed starters without version
  • doNotPinRenamedStarters - renamed starters (web -> webmvc) preserve no-version declaration
  • updateSpringBootVersionProperty - ${springBootVersion} in plugins block + gradle.properties updated
  • doNotPinStartersWithGStringVersion - GString version variable preserved, not collapsed to literal

Regression tests for moderneinc/customer-requests#1920
to verify that the Spring Boot 4 migration recipe:
- Does not pin BOM-managed starters that have no explicit version
- Does not pin renamed starters (e.g. web -> webmvc) with hardcoded versions
- Updates springBootVersion property in gradle.properties
- Preserves GString variable references in dependency declarations
Add gradle.properties with springBootVersion to the remaining two tests
that were using inline literal plugin versions. All four tests now
consistently verify that the springBootVersion property is updated to
4.0.x and that starters are not pinned.
@timtebeek timtebeek marked this pull request as draft February 26, 2026 22:08
@Jenson3210
Copy link
Contributor

@timtebeek timtebeek closed this Mar 3, 2026
@github-project-automation github-project-automation bot moved this from In Progress to Done in OpenRewrite Mar 3, 2026
@timtebeek timtebeek deleted the timtebeek/boot4-no-pin-starters branch March 3, 2026 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants