我对 Evosuite 生成有疑问。使用IntelliJ Maven集成生成测试集时出现如下错误,所有测试集生成失败。客户端错误日志:
[MASTER] 08:49:40.968 [pool-2-thread-1] ERROR TestSuiteGenerator - Problem for com.booktest.BooktestApplication. Full stack:
java.lang.IllegalArgumentException: null
at org.evosuite.shaded.org.objectweb.asm.ClassReader.<init>(ClassReader.java:160)
at org.evosuite.shaded.org.objectweb.asm.ClassReader.<init>(ClassReader.java:143)
at org.evosuite.shaded.org.objectweb.asm.ClassReader.<init>(ClassReader.java:418)
at org.evosuite.setup.InheritanceTreeGenerator.analyzeClassStream(InheritanceTreeGenerator.java:238)
at org.evosuite.setup.InheritanceTreeGenerator.createFromClassPath(InheritanceTreeGenerator.java:101)
at org.evosuite.setup.DependencyAnalysis.initInheritanceTree(DependencyAnalysis.java:77)
at org.evosuite.setup.DependencyAnalysis.analyzeClass(DependencyAnalysis.java:131)
at org.evosuite.TestSuiteGenerator.initializeTargetClass(TestSuiteGenerator.java:110)
at org.evosuite.TestSuiteGenerator.generateTestSuite(TestSuiteGenerator.java:130)
at org.evosuite.rmi.service.ClientNodeImpl$1.run(ClientNodeImpl.java:145)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
主错误日志:
[MASTER] 08:49:43.478 [main] ERROR SearchStatistics - No statistics has been saved because EvoSuite failed to generate any test case
[MASTER] 08:49:43.580 [main] ERROR TestGeneration - failed to write statistics data
Maven依赖:</p>
<dependency>
<groupId>org.evosuite</groupId>
<artifactId>evosuite-standalone-runtime</artifactId>
<version>1.0.6</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
<scope>test</scope>
</dependency>
<plugin>
<groupId>org.evosuite.plugins</groupId>
<artifactId>evosuite-maven-plugin</artifactId>
<version>1.0.6</version>
</plugin>
java版本:1.8.0_271