appcrawler不能通过包名测试吗?
需要指定应用的包名和activity来启动应用进行测试
一个yaml中可以定制多个package吗?也就是多个应用测试
通过adb方式测试,测试结果会报如下错误
2022-03-02 14:18:57 ERROR [Crawler.226.crawlWithRetry] create new session
Exception in thread “main” java.util.concurrent.ExecutionException: java.lang.StringIndexOutOfBoundsException: String index out of range: 0
at java.util.concurrent.FutureTask.report(FutureTask.java:122)
at java.util.concurrent.FutureTask.get(FutureTask.java:206)
at com.ceshiren.appcrawler.utils.LogicUtils$.$anonfun$asyncTask$1(LogicUtils.scala:75)
at scala.util.Try$.apply(Try.scala:210)
at com.ceshiren.appcrawler.utils.LogicUtils$.asyncTask(LogicUtils.scala:66)
at com.ceshiren.appcrawler.plugin.ReportPlugin.afterElementAction(ReportPlugin.scala:32)
at com.ceshiren.appcrawler.core.Crawler.$anonfun$afterElementAction$2(Crawler.scala:803)
at com.ceshiren.appcrawler.core.Crawler.$anonfun$afterElementAction$2$adapted(Crawler.scala:803)
at scala.collection.IterableOnceOps.foreach(IterableOnce.scala:563)
at scala.collection.IterableOnceOps.foreach$(IterableOnce.scala:561)
at scala.collection.AbstractIterable.foreach(Iterable.scala:919)
at com.ceshiren.appcrawler.core.Crawler.afterElementAction(Crawler.scala:803)
at com.ceshiren.appcrawler.core.Crawler.crawl(Crawler.scala:1024)
at com.ceshiren.appcrawler.core.Crawler.$anonfun$crawlWithRetry$1(Crawler.scala:214)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.scala:18)
at scala.util.Try$.apply(Try.scala:210)
at com.ceshiren.appcrawler.core.Crawler.crawlWithRetry(Crawler.scala:214)
at com.ceshiren.appcrawler.core.Crawler.start(Crawler.scala:171)
at com.ceshiren.appcrawler.AppCrawler$.startCrawl(AppCrawler.scala:319)
at com.ceshiren.appcrawler.AppCrawler$.parseParams(AppCrawler.scala:286)
at com.ceshiren.appcrawler.AppCrawler$.main(AppCrawler.scala:73)
at com.ceshiren.appcrawler.AppCrawler.main(AppCrawler.scala)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: 0
at java.lang.String.charAt(String.java:658)
at javassist.ClassPool.createCtClass(ClassPool.java:542)
at javassist.ClassPool.get0(ClassPool.java:518)
at javassist.ClassPool.getOrNull(ClassPool.java:461)
at com.ceshiren.appcrawler.plugin.scalatest.SuiteToClass$.genTestCaseClass(SuiteToClass.scala:42)
at com.ceshiren.appcrawler.plugin.scalatest.ScalaTestRuntime.$anonfun$genTestCase$2(ScalaTestRuntime.scala:28)
at com.ceshiren.appcrawler.plugin.scalatest.ScalaTestRuntime.$anonfun$genTestCase$2$adapted(ScalaTestRuntime.scala:21)
at scala.collection.immutable.List.foreach(List.scala:333)
at com.ceshiren.appcrawler.plugin.scalatest.ScalaTestRuntime.genTestCase(ScalaTestRuntime.scala:21)
at com.ceshiren.appcrawler.plugin.ReportPlugin.generateReport(ReportPlugin.scala:81)
at com.ceshiren.appcrawler.plugin.ReportPlugin.$anonfun$afterElementAction$1(ReportPlugin.scala:35)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.scala:18)
at com.ceshiren.appcrawler.utils.LogicUtils$$anon$1.call(LogicUtils.scala:69)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
报下标越界了
嗯,不知道在什么位置,appium方式没有问题