From 89711993d06e405dc23f88e035f906a7d7f69c48 Mon Sep 17 00:00:00 2001 From: spencergibb Date: Thu, 25 Mar 2021 16:51:32 -0400 Subject: [PATCH] Updates test for boot 2.5 --- .../SpringBootDependencyTests.java | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/spring-cloud-commons/src/test/java/org/springframework/cloud/configuration/SpringBootDependencyTests.java b/spring-cloud-commons/src/test/java/org/springframework/cloud/configuration/SpringBootDependencyTests.java index 3a5b545d..c8f489a4 100644 --- a/spring-cloud-commons/src/test/java/org/springframework/cloud/configuration/SpringBootDependencyTests.java +++ b/spring-cloud-commons/src/test/java/org/springframework/cloud/configuration/SpringBootDependencyTests.java @@ -173,11 +173,22 @@ public class SpringBootDependencyTests { then(verificationResult.action).isEmpty(); } - // @Ignore // FIXME: https://github.com/spring-cloud/spring-cloud-commons/issues/717 @Test public void should_match_against_current_manifest() { - verifyCurrentVersionFromManifest("2.4"); - verifyCurrentVersionFromManifest("2.4.x"); + try { + verifyCurrentVersionFromManifest("2.4"); + verifyCurrentVersionFromManifest("2.4.x"); + } + catch (AssertionError e) { + if (e.getMessage() != null && e.getMessage().contains("2.5.")) { + // we're likely running a boot 2.5 compatibility test, try 2.5 + verifyCurrentVersionFromManifest("2.5"); + verifyCurrentVersionFromManifest("2.5.x"); + } + else { + throw e; + } + } } private void verifyCurrentVersionFromManifest(String version) {