Parsing Flex SDK errors

init swf to flex before editig
This commit is contained in:
Jindra Petřík
2016-08-20 18:23:09 +02:00
parent a8ba726816
commit 5c4e07ec1b
13 changed files with 389 additions and 198 deletions

View File

@@ -3,9 +3,10 @@ package com.jpexs.decompiler.flash.flexsdk;
import com.jpexs.decompiler.flash.SWF;
import com.jpexs.decompiler.flash.abc.ScriptPack;
import com.jpexs.decompiler.flash.configuration.Configuration;
import com.jpexs.decompiler.flash.exporters.script.LinkReportExporter;
import com.jpexs.helpers.Helper;
import java.io.BufferedInputStream;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
@@ -13,9 +14,10 @@ import org.testng.annotations.Test;
public class As3ScriptReplacerTest {
@Test
//Commented out yet... there's no Flex SDK on build server
//@Test
public void testReplace() throws IOException, InterruptedException, Exception {
MxmlcAs3ScriptReplacer replacer = new MxmlcAs3ScriptReplacer(Configuration.flexSdkLocation.get(), new LinkReportExporter());
MxmlcAs3ScriptReplacer replacer = new MxmlcAs3ScriptReplacer(Configuration.flexSdkLocation.get());
SWF swf = new SWF(new BufferedInputStream(new FileInputStream("testdata/as3/as3.swf")), false);
String replacement = "package classes\n"
+ "{\n"