Skip to content

Commit

Permalink
Updates to support boot 3.5.0-SNAPSHOT
Browse files Browse the repository at this point in the history
  • Loading branch information
spencergibb committed Jan 16, 2025
1 parent 6bf064c commit bb2936d
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ public class CompatibilityVerifierProperties {
/**
* Default accepted versions for the Spring Boot dependency. You can set {@code x} for
* the patch version if you don't want to specify a concrete value. Example:
* {@code 3.4.x}
* {@code 3.5.x}
*/
private List<String> compatibleBootVersions = List.of("3.4.x");
private List<String> compatibleBootVersions = List.of("3.5.x");

public boolean isEnabled() {
return this.enabled;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class SpringBootVersionVerifier implements CompatibilityVerifier {

final Map<String, CompatibilityPredicate> ACCEPTED_VERSIONS = new HashMap<>() {
{
this.put("3.4", is3_4());
this.put("3.5", is3_5());
}
};

Expand Down Expand Up @@ -70,23 +70,23 @@ String getVersionFromManifest() {
return SpringBootVersion.getVersion();
}

CompatibilityPredicate is3_4() {
CompatibilityPredicate is3_5() {
return new CompatibilityPredicate() {

@Override
public String toString() {
return "Predicate for Boot 3.4";
return "Predicate for Boot 3.5";
}

@Override
public boolean isCompatible() {
try {
Class.forName("org.springframework.boot.autoconfigure.web.client.RestClientSsl");
return true;
}
catch (ClassNotFoundException e) {
return false;
}
// try {
// Class.forName("org.springframework.boot.autoconfigure.web.client.RestClientSsl");
return true;
// }
// catch (ClassNotFoundException e) {
// return false;
// }
}
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,8 @@ String getVersionFromManifest() {
@Test
public void should_match_against_current_manifest() {
try {
verifyCurrentVersionFromManifest("3.4");
verifyCurrentVersionFromManifest("3.4.x");
verifyCurrentVersionFromManifest("3.5");
verifyCurrentVersionFromManifest("3.5.x");
}
catch (AssertionError e) {
// if (e.getMessage() != null && e.getMessage().contains("3.3.")) {
Expand Down Expand Up @@ -212,7 +212,7 @@ String getVersionFromManifest() {
}
};
versionVerifier.ACCEPTED_VERSIONS.clear();
versionVerifier.ACCEPTED_VERSIONS.put("3.0", versionVerifier.is3_4());
versionVerifier.ACCEPTED_VERSIONS.put("3.0", versionVerifier.is3_5());

VerificationResult verificationResult = versionVerifier.verify();

Expand All @@ -230,7 +230,7 @@ String getVersionFromManifest() {
}
};
versionVerifier.ACCEPTED_VERSIONS.clear();
versionVerifier.ACCEPTED_VERSIONS.put("3.0", versionVerifier.is3_4());
versionVerifier.ACCEPTED_VERSIONS.put("3.0", versionVerifier.is3_5());

VerificationResult verificationResult = versionVerifier.verify();

Expand Down

0 comments on commit bb2936d

Please sign in to comment.