Verify that two-dimensional object arrays have the correct component type

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
Johannes Schindelin 2013-10-25 13:23:41 -05:00
parent 0ca8601777
commit 6f64e3aaab

View File

@ -67,5 +67,10 @@ public class Reflection {
expect(7.0 == (Double) Reflection.class.getMethod
("doubleMethod").invoke(null));
Class[][] array = new Class[][] { { Class.class } };
expect("[Ljava.lang.Class;".equals(array[0].getClass().getName()));
expect(Class[].class == array[0].getClass());
expect(array.getClass().getComponentType() == array[0].getClass());
}
}