summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Marie Henaff <jmhenaff@google.com>2014-09-11 16:52:16 +0200
committerJean-Marie Henaff <jmhenaff@google.com>2014-09-11 16:52:16 +0200
commitb7f82830c27c42f98ceca19b0e614f3e5cef200a (patch)
treeee4cac367a588769bdc2820879d9e089e8554cd4
parenta1ba5b090c002e864581a107865666bd077a456a (diff)
downloadtoolchain_jill-b7f82830c27c42f98ceca19b0e614f3e5cef200a.zip
toolchain_jill-b7f82830c27c42f98ceca19b0e614f3e5cef200a.tar.gz
toolchain_jill-b7f82830c27c42f98ceca19b0e614f3e5cef200a.tar.bz2
Fix Jill tests to handle changes made in Jack API
Pass a directory instead of file for output dex file Change-Id: I67a2cc19521074a42884fbd3c35571b6b7907aa4
-rw-r--r--jill/tests/com/android/jill/JillTestTools.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/jill/tests/com/android/jill/JillTestTools.java b/jill/tests/com/android/jill/JillTestTools.java
index 5e603f5..205254b 100644
--- a/jill/tests/com/android/jill/JillTestTools.java
+++ b/jill/tests/com/android/jill/JillTestTools.java
@@ -21,6 +21,7 @@ import com.android.jack.JarJarRules;
import com.android.jack.Options;
import com.android.jack.ProguardFlags;
import com.android.jack.TestTools;
+import com.android.jack.backend.dex.DexFileWriter;
import com.android.jack.util.ExecuteFile;
import java.io.File;
@@ -121,11 +122,11 @@ public class JillTestTools extends TestTools {
runJill(refJar, jackFile);
// Run Jack on .jack
- File jackDex = new File(testDir, "testjack.dex");
- compileJackToDex(new Options(), jackFile, jackDex, false);
+ File jackDexFolder = TestTools.createTempDir("jack", "dex");
+ compileJackToDex(new Options(), jackFile, jackDexFolder, false);
// Compare Jack Dex file to reference
new DexComparator(withDebugInfo, /* strict */false, /* compareDebugInfoBinary */ false,
- /* compareInstructionNumber */ false, 0f).compare(refDex, jackDex);
+ /* compareInstructionNumber */ false, 0f).compare(refDex, new File(jackDexFolder, DexFileWriter.DEX_FILENAME));
}
}