From 412d761b687629df55cadef6ba1f846dee48a6d5 Mon Sep 17 00:00:00 2001 From: Liam Miller-Cushon Date: Wed, 24 Jan 2024 15:24:53 -0800 Subject: [PATCH] Fix a test bug introduced by https://github.com/google/google-java-format/commit/430ba3b0e237b746157a3392663da4b4bb7c733d PiperOrigin-RevId: 601252048 --- .../googlejavaformat/java/FormatterIntegrationTest.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/core/src/test/java/com/google/googlejavaformat/java/FormatterIntegrationTest.java b/core/src/test/java/com/google/googlejavaformat/java/FormatterIntegrationTest.java index 5fb356750..26493b022 100644 --- a/core/src/test/java/com/google/googlejavaformat/java/FormatterIntegrationTest.java +++ b/core/src/test/java/com/google/googlejavaformat/java/FormatterIntegrationTest.java @@ -104,10 +104,9 @@ public static Iterable data() throws IOException { String expectedOutput = outputs.get(fileName); Optional version = VERSIONED_TESTS.inverse().get(fileName).stream().collect(toOptional()); - if (Runtime.version().feature() < version.orElse(Integer.MAX_VALUE)) { - continue; + if (Runtime.version().feature() >= version.orElse(Integer.MIN_VALUE)) { + testInputs.add(new Object[] {fileName, input, expectedOutput}); } - testInputs.add(new Object[] {fileName, input, expectedOutput}); } return testInputs; }