updated tests

Export test for exporting all files in testdata/decompile dir
This commit is contained in:
Jindra Petk
2013-07-13 13:06:51 +02:00
parent 7757cd3618
commit dc29b8f709
3 changed files with 100 additions and 3 deletions

View File

@@ -37,14 +37,14 @@ public class ActionScript2Test {
@BeforeClass
public void init() throws IOException {
swf = new SWF(new FileInputStream("testdata/as2/as2.swf"), false);
Configuration.setConfig("autoDeobfuscate", false);
swf = new SWF(new FileInputStream("testdata/as2/as2.swf"), false);
}
private void compareSrc(int frame, String expectedResult) {
DoActionTag doa = getFrameSource(frame);
assertNotNull(doa);
String actualResult = Highlighting.stripHilights(Action.actionsToSource(doa.getActions(swf.version), swf.version));
String actualResult = Highlighting.stripHilights(Action.actionsToSource(doa.getActions(swf.version), swf.version,""));
actualResult = actualResult.replaceAll("[ \r\n]", "");
expectedResult = expectedResult.replaceAll("[ \r\n]", "");
assertEquals(actualResult, expectedResult);