INVIVO-1

Jonathan Bell [2012-03-22 02:08:37]
INVIVO-1
Filename
Columbus2Tester/apt_generated/edu/columbia/cs/psl/metamorphic/example/ProcessorTester_tests.java
Columbus2Tester/src/edu/columbia/cs/psl/metamorphic/example/ProcessorTester.java
diff --git a/Columbus2Tester/apt_generated/edu/columbia/cs/psl/metamorphic/example/ProcessorTester_tests.java b/Columbus2Tester/apt_generated/edu/columbia/cs/psl/metamorphic/example/ProcessorTester_tests.java
index b33ffd7..cc25921 100644
--- a/Columbus2Tester/apt_generated/edu/columbia/cs/psl/metamorphic/example/ProcessorTester_tests.java
+++ b/Columbus2Tester/apt_generated/edu/columbia/cs/psl/metamorphic/example/ProcessorTester_tests.java
@@ -1,6 +1,15 @@
 package edu.columbia.cs.psl.metamorphic.example;
 public class ProcessorTester_tests {
 @SuppressWarnings("all")
+public static  java.lang.String pickFirstString_0 ( java.lang.String[] in, ProcessorTester ___object, java.lang.reflect.Method ___method) throws Exception {
+return (java.lang.String) ___method.invoke(___object,new edu.columbia.cs.psl.metamorphic.inputProcessor.impl.Shuffle().apply((Object) in));
+
+}
+@SuppressWarnings("all")
+public static  boolean pickFirstString_Check0 (java.lang.String orig, java.lang.String metamorphic, java.lang.String[] in) {
+if(orig == null && metamorphic != null) return false; if(orig == null && metamorphic == null) return true;return metamorphic.equals(orig);
+
+}@SuppressWarnings("all")
 public static  int findClosestValue_0 ( int[] values,  Integer target, ProcessorTester ___object, java.lang.reflect.Method ___method) throws Exception {
 return (Integer) ___method.invoke(___object,new edu.columbia.cs.psl.metamorphic.inputProcessor.impl.MultiplyByNumericConstant().apply((Object) values, 10), target * 10);

@@ -18,14 +27,5 @@ return (Integer) ___method.invoke(___object,new edu.columbia.cs.psl.metamorphic.
 public static  boolean findClosestValue_Check1 (int orig, int metamorphic, int[] values,  Integer target) {
 return metamorphic == orig + 10;

-}@SuppressWarnings("all")
-public static  java.lang.String pickFirstString_0 ( java.lang.String[] in, ProcessorTester ___object, java.lang.reflect.Method ___method) throws Exception {
-return (java.lang.String) ___method.invoke(___object,new edu.columbia.cs.psl.metamorphic.inputProcessor.impl.Shuffle().apply((Object) in));
-
-}
-@SuppressWarnings("all")
-public static  boolean pickFirstString_Check0 (java.lang.String orig, java.lang.String metamorphic, java.lang.String[] in) {
-if(orig == null && metamorphic != null) return false; if(orig == null && metamorphic == null) return true;return metamorphic.equals(orig);
-
 }
 }
\ No newline at end of file
diff --git a/Columbus2Tester/src/edu/columbia/cs/psl/metamorphic/example/ProcessorTester.java b/Columbus2Tester/src/edu/columbia/cs/psl/metamorphic/example/ProcessorTester.java
index 8c1f279..c763246 100644
--- a/Columbus2Tester/src/edu/columbia/cs/psl/metamorphic/example/ProcessorTester.java
+++ b/Columbus2Tester/src/edu/columbia/cs/psl/metamorphic/example/ProcessorTester.java
@@ -1,5 +1,6 @@
 package edu.columbia.cs.psl.metamorphic.example;

+import edu.columbia.cs.psl.invivo.runtime.AbstractInterceptor;
 import edu.columbia.cs.psl.metamorphic.runtime.annotation.Metamorphic;
 import edu.columbia.cs.psl.metamorphic.runtime.annotation.Rule;

@@ -44,6 +45,15 @@ public class ProcessorTester {
     		@Rule(test = "pickFirstString(\\Shuffle(in))", check="\\result")})
     private String pickFirstString(String[] in)
 	{
+    	try
+    	{
+    		int childThread = AbstractInterceptor.getThreadChildId();
+    		System.out.println("I'm in child " + childThread);
+    	}
+    	catch(IllegalStateException ex)
+    	{
+    		System.out.println("I'm in a parent");
+    	}
 		return in[0];
 	}
 }