[英]Java PIT classpath issue
I am having a folder "mutant" which contains a text file with just a single line called java.utils.Collection
. 我有一个“ mutant”文件夹,其中包含一个文本文件,只有一行称为
java.utils.Collection
。 I have generated test cases using Randoop and saved them in the same folder. 我已经使用Randoop生成了测试用例,并将它们保存在同一文件夹中。 The test cases have names RegressionTest*.java I am trying to run PIT now to generate mutants.
测试用例的名称为RegressionTest * .java。我现在尝试运行PIT来生成突变体。 The command that I am typing as per http://pitest.org/quickstart/commandline/ is the following---
我按照http://pitest.org/quickstart/commandline/输入的命令如下---
java -cp C:\Users\happy\OneDrive\Desktop\pitest-1.4.3.jar;C:\Users\happy\OneDrive\Desktop\pitest-command-line-1.4.3.jar;C:\Users\happy\OneDrive\Desktop\pitest-entry-1.4.3.jar;C:\Users\happy\OneDrive\Desktop\junit-4.10.jar;C:\Users\happy\OneDrive\Desktop\testng-6.8.5.jar
org.pitest.mutationtest.commandline.MutationCoverageReport
--reportDir C:\Users\happy\OneDrive\Desktop\report
--targetClasses myclasses.*
--targetTests mutant.Regression*
--sourceDirs C:\Users\happy\OneDrive\Desktop\mutant
and the error I am getting is Exception in thread "main". org.Pitest.help.PitHelpError: No mutations found. This probably means there is an issue with either the supplied classpath or filters
我得到的错误是
Exception in thread "main". org.Pitest.help.PitHelpError: No mutations found. This probably means there is an issue with either the supplied classpath or filters
Exception in thread "main". org.Pitest.help.PitHelpError: No mutations found. This probably means there is an issue with either the supplied classpath or filters
I believe that problem is associated with targetClasses. 我相信这个问题与targetClasses有关。 Anyone has any idea?
有人知道吗?
Collection
is in java.util
, not java.util s . Collection
是在java.util
,而不是java.util中秒 。
You can check that there is indeed generated tests. 您可以检查是否确实生成了测试。
Furthermore, I think the tested code you want Pitest to mutate should have it's source code indicated by --sourceDirs . 此外,我认为您希望Pitest进行变异的测试代码应具有--sourceDirs指示的源代码。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.