Adding sypet to repo
[Benchmarks_CSolver.git] / sypet / benchmarks / joda / 22 / TestSource.java
diff --git a/sypet/benchmarks/joda/22/TestSource.java b/sypet/benchmarks/joda/22/TestSource.java
new file mode 100644 (file)
index 0000000..6d71445
--- /dev/null
@@ -0,0 +1,25 @@
+public static boolean test0() throws Throwable {               
+    org.joda.time.DateTime birth = new org.joda.time.DateTime(1990, 11, 13, 2, 0);
+    int age = getAge(birth);
+       return (age == 26);     
+}
+       
+
+public static boolean test1() throws Throwable {               
+    org.joda.time.DateTime birth = new org.joda.time.DateTime(1980, 11, 13, 2, 0);
+    int age = getAge(birth);
+       return (age == 36);     
+}
+
+public static boolean test2() throws Throwable {               
+    org.joda.time.DateTimeZone SH = org.joda.time.DateTimeZone.forID("Asia/Shanghai");
+    org.joda.time.DateTime birth = new org.joda.time.DateTime(1980, 11, 13, 2, 0, SH);
+    int age = getAge(birth);
+       return (age == 35);     
+}
+
+public static boolean test() throws Throwable {
+               
+    return test0() && test1(); 
+
+}