JUnit was not found on the classpath. PIT requires JUnit 4.6

196 views
Skip to first unread message

Avinash Garimella

unread,
Oct 21, 2020, 10:34:45 AM10/21/20
to PIT Users

I have root build.gradle and a subproject. Based on the recommendation for 1.5.1, i have configured the subproject as below:

plugins {
id 'java-application'
id 'info.solidsoft.pitest' version '1.5.1'
}

pitest {
targetClasses = ['com.test.*']
pitestVersion = "1.5.1"
outputFormats = ['HTML']
timestampedReports = false
verbose = true
junit5PluginVersion = '0.12'
}

However i see the following error:

7:12:36 PM PIT >> INFO : MINION : 7:12:36 PM PIT >> SEVERE : JUnit was not found on the classpath. PIT requires JUnit 4.6 or above.
See http://pitest.org for more details.

7:12:36 PM PIT >> SEVERE : Error generating coverage. Please check that your classpath contains modern JUnit 4 or PIT test plugin for other test tool (JUnit 5, TestNG, ...) is enabled.
Exception in thread "main" org.pitest.util.PitError: Coverage generation minion exited abnormally. Please check the classpath and/or enable test plugin for used test tool.

Marcin Zajączkowski

unread,
Oct 21, 2020, 10:50:56 AM10/21/20
to pitu...@googlegroups.com
Avinash, you created an issue ticket in gradle-pitest-plugin 45 minutes ago:
https://github.com/szpak/gradle-pitest-plugin/issues/236

30 minutes later you sent this message to the mailing list.

As you decided to use an issue tracker you could wait a little bit
longer before using an another channel of communication (I haven't
checked, but maybe there is also a similar Stack Overflow question ;) )
to do not flood them with the same problem.

I responded a few minutes ago in the aforementioned ticket and propose
to continue there.

Marcin
--
https://blog.solidsoft.pl/ - Working code is not enough
Reply all
Reply to author
Forward
0 new messages