如何解决trace.zip文件的内容无法在仪器中打开
我使用时间分析器工具通过ios应用启动了性能测试
取回乐器trace.zip
文件后
run.zip
中的跟踪文件无法打开
有人可能曾经遇到过这个问题
我的代码
public void testAppActivity() throws Exception {
try {
HashMap<String,Object> args = new HashMap<>();
args.put("timeout",60000);
args.put("pid","current");
args.put("profileName","Time Profiler");
driver.executeScript("mobile: startPerfRecord",args);
testchannelnumbers(driver);
OpenChannelDeviceOne(driver);
PTT(driver);
args = new HashMap<>();
args.put("profileName","Time Profiler");
String b64Zip = (String)driver.executeScript("mobile: stopPerfRecord",args);
byte[] bytesZip = Base64.getMimeDecoder().decode(b64Zip);
FileOutputStream stream = new FileOutputStream(traceZip);
stream.write(bytesZip);
stream.close();
} finally {
driver.quit();
}
}
解决方法
好,这是与提取zip有关的appium错误
解决方法:
只需将解压缩的内容提取到一个文件夹中,然后将该文件夹重命名为“
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。