From b43f9c3d057abb7d81a62807c7b10fb5b157f00c Mon Sep 17 00:00:00 2001 From: Miles Ziemer <45497130+milesziemer@users.noreply.github.com> Date: Wed, 7 Feb 2024 16:01:29 -0500 Subject: [PATCH 1/3] Fix CI for 1.44.0 bump (#142) A test depended on the ordering of validation events, which 1.44.0 changes. --- .../amazon/smithy/lsp/SmithyInterfaceTest.java | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/test/java/software/amazon/smithy/lsp/SmithyInterfaceTest.java b/src/test/java/software/amazon/smithy/lsp/SmithyInterfaceTest.java index 9db0e0d3..77fd2945 100644 --- a/src/test/java/software/amazon/smithy/lsp/SmithyInterfaceTest.java +++ b/src/test/java/software/amazon/smithy/lsp/SmithyInterfaceTest.java @@ -17,7 +17,6 @@ import static org.junit.Assert.assertTrue; import static org.junit.Assert.assertFalse; -import static org.junit.Assert.assertEquals; import java.io.File; import java.nio.file.Path; @@ -25,6 +24,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.List; +import java.util.Optional; import java.util.stream.Collectors; import org.eclipse.lsp4j.jsonrpc.messages.Either; import org.junit.Test; @@ -105,10 +105,16 @@ public void runValidators() throws Exception { assertTrue(result.isRight()); List validationEvents = result.getRight().getValidationEvents(); assertFalse(validationEvents.isEmpty()); - assertEquals( - "Proto index 1 is used muliple times in members name,age of shape (structure: `some.test#MyStruct`).", - validationEvents.get(0).getMessage() - ); + + String expectedMessage = "Proto index 1 is used muliple times in members name," + + "age of shape (structure: `some.test#MyStruct`)."; + Optional matchingEvent = validationEvents.stream() + .filter(ev ->ev.getMessage().equals(expectedMessage)).findFirst(); + + if (!matchingEvent.isPresent()) { + throw new AssertionError("Expected validation event with message `" + expectedMessage + + "`, but events were " + validationEvents); + } } private static List getFiles(String... filenames) throws Exception { From c7931522c11c8b07a8a6eb13ecfad5370c18206e Mon Sep 17 00:00:00 2001 From: smithy-automation <127955164+smithy-automation@users.noreply.github.com> Date: Wed, 21 Feb 2024 06:37:17 -0800 Subject: [PATCH 2/3] Update Smithy Version (#144) Co-authored-by: Smithy Automation --- gradle.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 590aa871..8b3a8dca 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1 +1 @@ -smithyVersion=1.43.0 +smithyVersion=1.45.0 From a0ed74918133364ec6981b067396fb9792adfe2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Koz=C5=82owski?= Date: Tue, 5 Mar 2024 18:46:26 +0100 Subject: [PATCH 3/3] bump smithy to 1.45.0 --- build.sc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/build.sc b/build.sc index 62d5837f..b798e4bb 100644 --- a/build.sc +++ b/build.sc @@ -9,9 +9,9 @@ object lsp extends MavenModule with PublishModule { def ivyDeps = Agg( ivy"org.eclipse.lsp4j:org.eclipse.lsp4j:0.14.0", - ivy"software.amazon.smithy:smithy-model:1.41.0", - ivy"software.amazon.smithy:smithy-build:1.41.0", - ivy"software.amazon.smithy:smithy-cli:1.41.0", + ivy"software.amazon.smithy:smithy-model:1.45.0", + ivy"software.amazon.smithy:smithy-build:1.45.0", + ivy"software.amazon.smithy:smithy-cli:1.45.0", ivy"com.disneystreaming.smithy:smithytranslate-formatter-jvm-java-api:0.3.10" )