1.1 --- a/src/test/java/org/apidesign/java4browser/InstanceTest.java Thu Sep 20 09:29:42 2012 +0200
1.2 +++ b/src/test/java/org/apidesign/java4browser/InstanceTest.java Thu Sep 20 10:26:59 2012 +0200
1.3 @@ -49,7 +49,31 @@
1.4 Double.valueOf(31)
1.5 );
1.6 }
1.7 -
1.8 +
1.9 + @Test public void isNull() throws Exception {
1.10 + assertExec(
1.11 + "Yes, we are instance",
1.12 + "org_apidesign_java4browser_Instance_isNullZ",
1.13 + Double.valueOf(0.0)
1.14 + );
1.15 + }
1.16 + /*
1.17 + @Test public void isInstanceOf() throws Exception {
1.18 + assertExec(
1.19 + "Yes, we are instance",
1.20 + "org_apidesign_java4browser_Instance_instanceOfZZ",
1.21 + Double.valueOf(1.0), true
1.22 + );
1.23 + }
1.24 +
1.25 + @Test public void notInstanceOf() throws Exception {
1.26 + assertExec(
1.27 + "No, we are not an instance",
1.28 + "org_apidesign_java4browser_Instance_instanceOfZZ",
1.29 + Double.valueOf(0.0), false
1.30 + );
1.31 + }
1.32 + */
1.33 private static void assertExec(String msg, String methodName, Object expRes, Object... args) throws Exception {
1.34 StringBuilder sb = new StringBuilder();
1.35 Invocable i = StaticMethodTest.compileClass(sb, "Instance.class", "InstanceSub.class");