Assert.assertEquals("字符串合并", "a+\"a\"+\"b\"", getResult("a+'a'+'b'"));
}
private String getResult(String data) throws Exception {
Writer writer = new StringWriter();
new JSCompressor().compress(new StringReader(data), writer, false,
JSCompressor.SEMANTICS);
return writer.toString();
}