Skip to content

Commit 674cfe0

Browse files
committed
Add test for failsafe.
1 parent 5c3fa69 commit 674cfe0

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

java/test/processing/mode/java/debug/VariableNodeTests.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ public void describeNestedArrayMixed() {
7272
Assert.assertEquals(node.getStringValue(), "instance of int[5][7][][]");
7373
}
7474

75+
@Test
76+
public void describeArrayFailsafe() {
77+
Value value = buildMockValue("instance of int[x][7] (id=998)");
78+
VariableNode node = new VariableNode("test", "int[][][][]", value);
79+
Assert.assertEquals(node.getStringValue(), "instance of int[x][7] (id=998));
80+
}
81+
7582
private Value buildMockValue(String toStringValue) {
7683
Value value = Mockito.mock(Value.class);
7784
Mockito.when(value.toString()).thenReturn(toStringValue);

0 commit comments

Comments
 (0)