Options Cleanup

- remove ugly Hashmap passing
 - create ApkOptions
 - refactor based on ApkOptions
This commit is contained in:
Connor Tumbleson
2014-11-01 21:07:02 -05:00
parent a7d8ca9086
commit 40fdfc50a1
9 changed files with 149 additions and 140 deletions

View File

@ -42,7 +42,7 @@ public class BuildAndDecodeJarTest {
LOGGER.info("Building testjar.jar...");
File testJar = new File(sTmpDir, "testjar.jar");
new Androlib().build(sTestOrigDir, testJar, TestUtils.returnStockHashMap(),"");
new Androlib().build(sTestOrigDir, testJar);
LOGGER.info("Decoding testjar.jar...");
ApkDecoder apkDecoder = new ApkDecoder(testJar);

View File

@ -44,7 +44,7 @@ public class BuildAndDecodeTest {
LOGGER.info("Building testapp.apk...");
File testApk = new File(sTmpDir, "testapp.apk");
new Androlib().build(sTestOrigDir, testApk, TestUtils.returnStockHashMap(),"");
new Androlib().build(sTestOrigDir, testApk);
LOGGER.info("Decoding testapp.apk...");
ApkDecoder apkDecoder = new ApkDecoder(testApk);

View File

@ -76,18 +76,6 @@ public abstract class TestUtils {
}
}
public static HashMap<String, Boolean> returnStockHashMap() throws BrutException {
HashMap<String, Boolean> tmp = new HashMap<String, Boolean>();
tmp.put("forceBuildAll", false);
tmp.put("debug", false);
tmp.put("verbose", false);
tmp.put("framework", false);
tmp.put("update", false);
tmp.put("copyOriginal", false);
return tmp;
}
/*
* TODO: move to brut.util.Jar - it's not possible for now, because below
* implementation uses brut.dir. I think I should merge all my projects to