Move main method tests from gtests to oat tests
Change-Id: Ifffa4d083488114d6cc14d578ec2be7db8a7553f
diff --git a/test/ExceptionTest/ExceptionTest.java b/test/ExceptionTest/ExceptionTest.java
index 13ef058..973e9e9 100644
--- a/test/ExceptionTest/ExceptionTest.java
+++ b/test/ExceptionTest/ExceptionTest.java
@@ -139,6 +139,7 @@
public static void main(String[] args) {
+ boolean failure = false;
int res;
res = nullCheckTestNoThrow(1976);
@@ -146,13 +147,18 @@
System.out.println("nullCheckTestNoThrow PASSED");
} else {
System.out.println("nullCheckTestNoThrow FAILED: " + res);
+ failure = true;
}
+if (false) { // TODO: enable this test when passing
res = nullCheckTestThrow(1976);
if (res == 2057) {
- System.out.println("nullCheckTestNoThrow PASSED");
+ System.out.println("nullCheckTestThrow PASSED");
} else {
- System.out.println("nullCheckTestNoThrow FAILED: " + res);
+ System.out.println("nullCheckTestThrow FAILED: " + res);
+ failure = true;
}
+}
+ System.exit(failure ? 1 : 0);
}
}