From 5d392924ba3fd0ca73b6d1f94ad100e16004c941 Mon Sep 17 00:00:00 2001 From: Noah Santschi-Cooney Date: Wed, 9 Sep 2020 11:56:49 +0100 Subject: [PATCH] Added test case for JLSCorrectness with simpleName List[] --- src/test/java/spoon/generating/CorrectIdentifierTest.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/test/java/spoon/generating/CorrectIdentifierTest.java b/src/test/java/spoon/generating/CorrectIdentifierTest.java index 6719088e7b0..23e6126700d 100644 --- a/src/test/java/spoon/generating/CorrectIdentifierTest.java +++ b/src/test/java/spoon/generating/CorrectIdentifierTest.java @@ -69,4 +69,10 @@ public void correctIdentiferUtfChinese() { CtLocalVariableReference localVariableRef = new Launcher().getFactory().createLocalVariableReference(); assertDoesNotThrow(() -> localVariableRef.setSimpleName("処理")); } + + @Test + public void correctSquareBrackets() { + CtLocalVariableReference localVariableRef = new Launcher().getFactory().createLocalVariableReference(); + assertDoesNotThrow(() -> localVariableRef.setSimpleName("List[]")); + } }