diff --git a/teavm-classlib/src/main/java/org/teavm/classlib/java/lang/TClassTests.java b/teavm-classlib/src/main/java/org/teavm/classlib/java/lang/TClassTests.java index 6c73749b8..ead653df2 100644 --- a/teavm-classlib/src/main/java/org/teavm/classlib/java/lang/TClassTests.java +++ b/teavm-classlib/src/main/java/org/teavm/classlib/java/lang/TClassTests.java @@ -25,6 +25,16 @@ class TClassTests { @Test public void arrayClassConsideredArray() { - assertFalse(Object[].class.isArray()); + assertTrue(Object[].class.isArray()); + } + + @Test + public void arrayComponentTypeDetected() { + assertEquals(Object.class, Object[].class.getComponentType()); + } + + @Test + public void nonArrayComponentTypeIsNull() { + assertNull(Object.class.getComponentType()); } }