EvoSuite / evosuite

EvoSuite - automated generation of JUnit test suites for Java classes
http://www.evosuite.org
GNU Lesser General Public License v3.0
823 stars 341 forks source link

Sample code to run evosuite code coverage using jacoco/sonar using gradle #438

Open reply2techie opened 1 year ago

reply2techie commented 1 year ago

Context

Please provide below a detailed introduction to the issue itself, and describe what you were doing when the issue happened. Or, what do you want to achieve?

I am working on a POC project to execute evosuite generated test cases to prove out the code coverage is sufficient enough. However after complete jacoco and sonar implementations, the code coverage still shows as 0%. I read article in evouite site that has the maven configuration to run the jacoco code coverage offline. However, I am using gradle. Is there a sample project that I can refer for running code coverage offline using Gradle?

Steps to Reproduce

Please break down here below all the needed steps to reproduce the issue. [If possible, please upload an example of the project you are generating tests for.]

  1. visit https://www.evosuite.org/documentation/measuring-code-coverage/

EvoSuite Arguments

Please provide the whole EvoSuite commmand you executed (if relevant)

Current Result

Please describe here below the current result you got (if relevant) [if relevant, include a screenshot]

Expected result

Please describe here below what should be the expected behaviour (if relevant)

Additional info

Please add any information of interest here below