From 4b5bcd3bca2726ab8ded2f7ad1061d6cd489d4a0 Mon Sep 17 00:00:00 2001 From: Benjamin Davies Date: Thu, 21 Mar 2024 19:38:05 +1300 Subject: [PATCH] Fix compatibility with Java 8 --- .../plantuml/cheneer/command/CommandAssociateTest.java | 4 ++-- .../cheneer/command/CommandCreateAttributeTest.java | 4 ++-- .../plantuml/cheneer/command/CommandCreateEntityTest.java | 4 ++-- .../plantuml/cheneer/command/CommandEndGroupTest.java | 4 ++-- .../plantuml/cheneer/command/CommandMultiSubclassTest.java | 7 +++---- .../cheneer/command/CommandSimpleSubclassTest.java | 4 ++-- 6 files changed, 13 insertions(+), 14 deletions(-) diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandAssociateTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandAssociateTest.java index cb72a51fa..1012443b6 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandAssociateTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandAssociateTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import java.util.List; +import java.util.ArrayList; import org.junit.jupiter.api.Test; @@ -20,7 +20,7 @@ public class CommandAssociateTest { private final Command command = new CommandAssociate(); - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parse() { diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandCreateAttributeTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandCreateAttributeTest.java index 08c2139f8..d2735db5d 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandCreateAttributeTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandCreateAttributeTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import java.util.List; +import java.util.ArrayList; import org.junit.jupiter.api.Test; @@ -21,7 +21,7 @@ public class CommandCreateAttributeTest { private final Command command = new CommandCreateAttribute(); - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parse() { diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandCreateEntityTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandCreateEntityTest.java index 7226e5c5e..f9730f537 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandCreateEntityTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandCreateEntityTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import java.util.List; +import java.util.ArrayList; import org.junit.jupiter.api.Test; @@ -21,7 +21,7 @@ public class CommandCreateEntityTest { private final Command command = new CommandCreateEntity(); - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parseEntity() { diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandEndGroupTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandEndGroupTest.java index dfa696234..99f4a5591 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandEndGroupTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandEndGroupTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import java.util.List; +import java.util.ArrayList; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; @@ -25,7 +25,7 @@ public class CommandEndGroupTest { private final Command command = new CommandEndGroup(); @Spy - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parse() { diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandMultiSubclassTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandMultiSubclassTest.java index d6b0c9168..d1fc338ed 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandMultiSubclassTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandMultiSubclassTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import net.sourceforge.plantuml.core.UmlSource; +import java.util.ArrayList; import org.junit.jupiter.api.Test; @@ -10,19 +10,18 @@ import net.sourceforge.plantuml.abel.Link; import net.sourceforge.plantuml.cheneer.ChenEerDiagram; import net.sourceforge.plantuml.command.Command; import net.sourceforge.plantuml.command.CommandExecutionResult; +import net.sourceforge.plantuml.core.UmlSource; import net.sourceforge.plantuml.decoration.LinkMiddleDecor; import net.sourceforge.plantuml.klimt.color.NoSuchColorException; import net.sourceforge.plantuml.regex.IRegex; import net.sourceforge.plantuml.regex.RegexResult; import net.sourceforge.plantuml.utils.BlocLines; -import java.util.List; - public class CommandMultiSubclassTest { private final Command command = new CommandMultiSubclass(); - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parse() { diff --git a/test/net/sourceforge/plantuml/cheneer/command/CommandSimpleSubclassTest.java b/test/net/sourceforge/plantuml/cheneer/command/CommandSimpleSubclassTest.java index ed27ae6b5..22a33b2c5 100644 --- a/test/net/sourceforge/plantuml/cheneer/command/CommandSimpleSubclassTest.java +++ b/test/net/sourceforge/plantuml/cheneer/command/CommandSimpleSubclassTest.java @@ -2,7 +2,7 @@ package net.sourceforge.plantuml.cheneer.command; import static org.assertj.core.api.Assertions.assertThat; -import java.util.List; +import java.util.ArrayList; import org.junit.jupiter.api.Test; @@ -21,7 +21,7 @@ public class CommandSimpleSubclassTest { private final Command command = new CommandSimpleSubclass(); - private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(List.of(), false), null); + private final ChenEerDiagram diagram = new ChenEerDiagram(UmlSource.create(new ArrayList<>(), false), null); @Test void test_parseSubset() {