// Path: FlowTwist/src/flow/twist/AbstractAnalysis.java
// public abstract class AbstractAnalysis {
// 
// 	public void execute() {
// 		ArrayList<String> argList = createArgs();
// 		AnalysisReporting.setSootArgs(argList);
// 		registerAnalysisTransformer();
// 		soot.Main.main(argList.toArray(new String[0]));
// 	}
// 
// 	protected abstract ArrayList<String> createArgs();
// 
// 	protected abstract void executeAnalysis();
// 
// 	private static void insertNopStatements() {
// 		for (Iterator<MethodOrMethodContext> iter = Scene.v().getReachableMethods().listener(); iter.hasNext();) {
// 			SootMethod m = iter.next().method();
// 			if (m.hasActiveBody()) {
// 				Body b = m.getActiveBody();
// 				NopStmt newNopStmt = Jimple.v().newNopStmt();
// 				newNopStmt.addAllTagsOf(b.getUnits().getFirst());
// 				b.getUnits().addFirst(newNopStmt);
// 
// 				ActiveBodyVerifier.markActive(m);
// 			} else
// 				ActiveBodyVerifier.markInactive(m);
// 		}
// 	}
// 
// 	private void registerAnalysisTransformer() {
// 		PackManager.v().getPack("wjtp").add(new Transform("wjtp.permissionAnalysis", new SceneTransformer() {
// 			protected void internalTransform(String phaseName, @SuppressWarnings("rawtypes") Map options) {
// 				// Stats.print();
// 				insertNopStatements();
// 				executeAnalysis();
// 			}
// 		}));
// 	}
// }


import java.io.File;
import java.util.ArrayList;
import java.util.Arrays;
import org.junit.After;
import org.junit.Before;
import soot.G;
import flow.twist.AbstractAnalysis;
import flow.twist.util.AnalysisUtil;
package flow.twist.test.util;




public abstract class AbstractAnalysisTest {

	protected void runAnalysis(TestAnalysis analysis) {
		analysis.execute();
	}

	@Before
	public void setUp() throws Exception {
// Path: FlowTwist/src/flow/twist/AbstractAnalysis.java
// public abstract class AbstractAnalysis {
// 
// 	public void execute() {
// 		ArrayList<String> argList = createArgs();
// 		AnalysisReporting.setSootArgs(argList);
// 		registerAnalysisTransformer();
// 		soot.Main.main(argList.toArray(new String[0]));
// 	}
// 
// 	protected abstract ArrayList<String> createArgs();
// 
// 	protected abstract void executeAnalysis();
// 
// 	private static void insertNopStatements() {
// 		for (Iterator<MethodOrMethodContext> iter = Scene.v().getReachableMethods().listener(); iter.hasNext();) {
// 			SootMethod m = iter.next().method();
// 			if (m.hasActiveBody()) {
// 				Body b = m.getActiveBody();
// 				NopStmt newNopStmt = Jimple.v().newNopStmt();
// 				newNopStmt.addAllTagsOf(b.getUnits().getFirst());
// 				b.getUnits().addFirst(newNopStmt);
// 
// 				ActiveBodyVerifier.markActive(m);
// 			} else
// 				ActiveBodyVerifier.markInactive(m);
// 		}
// 	}
// 
// 	private void registerAnalysisTransformer() {
// 		PackManager.v().getPack("wjtp").add(new Transform("wjtp.permissionAnalysis", new SceneTransformer() {
// 			protected void internalTransform(String phaseName, @SuppressWarnings("rawtypes") Map options) {
// 				// Stats.print();
// 				insertNopStatements();
// 				executeAnalysis();
// 			}
// 		}));
// 	}
// }


// Path: FlowTwist/test/flow/twist/test/util/AbstractAnalysisTest.java
import java.io.File;
import java.util.ArrayList;
import java.util.Arrays;
import org.junit.After;
import org.junit.Before;
import soot.G;
import flow.twist.AbstractAnalysis;
import flow.twist.util.AnalysisUtil;

package flow.twist.test.util;




public abstract class AbstractAnalysisTest {

	protected void runAnalysis(TestAnalysis analysis) {
		analysis.execute();
	}

	@Before
	public void setUp() throws Exception {
		String jrePath = System.getProperty("java.home");