Exceptions when runing PITEST on the test cases generated by Evosuite

641 views
Skip to first unread message

Justin Civi

unread,
Jun 7, 2016, 8:43:37 AM6/7/16
to PIT Users
Dear All

I am currently running PiTest on the JUnit test cases generated by Evosuite.
It's said in the documentation that evosuite-standalone-runtime.jar is required to run the junit test cases generated by Evosuite.

When I didn't include this library in the class path, PiTest reported that it could not find any test cases.




8:35:20 PM PIT >> INFO : Verbose logging is disabled. If you encounter an problem please enable it before reporting an issue.
8:35:21 PM PIT >> INFO : Sending 1 test classes to minion
8:35:21 PM PIT >> INFO : Sent tests to minion
8:35:21 PM PIT >> INFO : MINION : 8:35:21 PM PIT >> INFO : Checking environment
8:35:21 PM PIT >> INFO : Found  0 tests

8:35:21 PM PIT >> INFO : MINION : 8:35:21 PM PIT >> INFO : Dependency analysis reduced number of potential tests by 0

8:35:21 PM PIT >> INFO : MINION : 8:35:21 PM PIT >> INFO : 0 tests received




When I included this in the class path, PiTest found the test cases correctly, while had some strange exceptions:





Please copy and paste the information and the complete stacktrace below when reporting an issue
VM : OpenJDK 64-Bit Server VM
Vendor : Oracle Corporation
Version : 25.91-b14
Uptime : 1666
Input ->
 1 : -javaagent:/tmp/14653022025
8:23:24 PM PIT >> INFO : MINION : 42031693225737969133763801195334263343.jar
BootClassPathSupported : true

        at org.pitest.util.Unchecked.translateCheckedException(Unchecked.java:20)
        at org.pitest.junit.adapter.AdaptedJUnitTestUnit.execute(AdaptedJUnitTestUnit.java:91)
        at org.pitest.cove
8:23:24 PM PIT >> INFO : MINION : rage.execute.CoverageDecorator.execute(CoverageDecorator.java:50)
        at org.pitest.testapi.execute.containers.UnContainer.execute(UnContainer.java:32)
        at org.pitest.testapi.execute.Pitest.executeTests(Pitest.java:59)
8:23:24 PM PIT >> INFO : MINION : n(Pitest.java:50)
        at org.pitest.coverage.execute.CoverageWorker.run(CoverageWorker.java:52)
        ... 1 more
Caused by: org.pitest.util.PitError:  : only whitespace content allowed before start tag and not j (position: START_DOCUMENT seen j... @1:1)

Please c
8:23:24 PM PIT >> INFO : MINION : opy and paste the information and the complete stacktrace below when reporting an issue
VM : OpenJDK 64-Bit Server VM
Vendor : Oracle Corporation
Version : 25.91-b14
Uptime : 1665
Input ->
 1 : -javaagent:/tmp/146530220254203169322573796913376380119533426
8:23:24 PM PIT >> INFO : MINION : 3343.jar
BootClassPathSupported : true

        at org.pitest.util.Unchecked.translateCheckedException(Unchecked.java:20)
        at org.pitest.junit.adapter.AdaptedJUnitTestUnit.executeInDifferentClassLoader(AdaptedJUnitTestUnit.java:153)
        at org.pitest.junit.adapter.A
8:23:24 PM PIT >> INFO : MINION : daptedJUnitTestUnit.execute(AdaptedJUnitTestUnit.java:80)
        ... 6 more
Caused by: org.pitest.reloc.xstream.io.StreamException:  : only whitespace content allowed before start tag and not j (position: START_DOCUMENT seen j... @1:1)
        at org.pitest.reloc.xstr
8:23:24 PM PIT >> INFO : MINION : eam.io.xml.XppReader.pullNextEvent(XppReader.java:124)
        at org.pitest.reloc.xstream.io.xml.AbstractPullReader.readRealEvent(AbstractPullReader.java:148)
        at org.pitest.reloc.xstream.io.xml.AbstractPullReader.readEvent(AbstractPullReader.java:141)
        at org.p
8:23:24 PM PIT >> INFO : MINION : itest.reloc.xstream.io.xml.AbstractPullReader.move(AbstractPullReader.java:118)
        at org.pitest.reloc.xstream.io.xml.AbstractPullReader.moveDown(AbstractPullReader.java:103)
        at org.pitest.reloc.xstream.io.xml.XppReader.<init>(XppReader.java:63)
        at org.pit
8:23:24 PM PIT >> INFO : MINION : est.reloc.xstream.io.xml.AbstractXppDriver.createReader(AbstractXppDriver.java:54)
        at org.pitest.reloc.xstream.XStream.fromXML(XStream.java:1061)
        at org.pitest.reloc.xstream.XStream.fromXML(XStream.java:1052)
        at org.pitest.util.IsolationUtils.fromXml(Is
8:23:24 PM PIT >> INFO : MINION : olationUtils.java:124)
        at org.pitest.testapi.foreignclassloader.Events.applyEvents(Events.java:17)
        at org.pitest.junit.adapter.AdaptedJUnitTestUnit.convertStringsToResults(AdaptedJUnitTestUnit.java:160)
        at org.pitest.junit.adapter.AdaptedJUnitTestUnit.e
8:23:24 PM PIT >> INFO : MINION : xecuteInDifferentClassLoader(AdaptedJUnitTestUnit.java:151)
        ... 7 more
Caused by: org.pitest.reloc.xmlpull.v1.XmlPullParserException: only whitespace content allowed before start tag and not j (position: START_DOCUMENT seen j... @1:1)
        at org.pitest.relo
8:23:24 PM PIT >> INFO : MINION : c.xmlpull.mxp1.MXParser.parseProlog(MXParser.java:1519)
        at org.pitest.reloc.xmlpull.mxp1.MXParser.nextImpl(MXParser.java:1395)
        at org.pitest.reloc.xmlpull.mxp1.MXParser.next(MXParser.java:1093)
        at org.pitest.reloc.xstream.io.xml.XppReader.pullNextEvent(
8:23:24 PM PIT >> INFO : MINION : XppReader.java:109)
        ... 19 more

8:23:24 PM PIT >> SEVERE : Coverage generator Minion exited abnormally due to UNKNOWN_ERROR
Exception in thread "main" org.pitest.util.PitError: Coverage generation minion exited abnormally!


I'm not really sure how to go about debugging this, so if anyone has faced a similar issue I'd be really grateful for any pointers on how this could be debugged.

I am also grateful if anyone can share me some experiences on running PiTest on the test cases generated by Evosuite :-) 

Thanks in advance!
Best Wishes
Ming

henry

unread,
Jun 7, 2016, 9:27:25 AM6/7/16
to PIT Users
On Tuesday, 7 June 2016 13:43:37 UTC+1, Justin Civi wrote:
Dear All

I am currently running PiTest on the JUnit test cases generated by Evosuite.
It's said in the documentation that evosuite-standalone-runtime.jar is required to run the junit test cases generated by Evosuite.
 
When I included this in the class path, PiTest found the test cases correctly, while had some strange exceptions:


Not seen this error before. Are you using the latest version of pitest (1.1.10)?

There are reports of using pitest with evosuite successfully 


Which note that some features of evosuite need to be disabled.

It may be worth asking questions in the evo suite group.

Henry 

Justin Civi

unread,
Jun 7, 2016, 10:23:05 AM6/7/16
to PIT Users
Hi Henry

Thanks very much for your reply !
Yes, I am using the latest version, and the following is my running command:

java -cp ./lib/pitest-command-line-1.1.10.jar:./lib/junit-4.12.jar:./lib/pitest-1.1.10.jar:./lib/hamcrest-all-1.3.jar:./evosuite-tests:./targets/commons-math3-3.6.1/:./lib/slf4j-simple-1.6.1.jar \
org.pitest.mutationtest.commandline.MutationCoverageReport \
--reportDir ./testing \
--sourceDirs . \
--targetClasses org.apache.commons.math3.* \
--mutators ALL \
--targetTests org.apache.commons.math3.optim.SimplePointChecker_ESTest

I have included slf4j library in the class path because there is a warning if it is not included.
Thanks very much for your advice, and I will post it in the Evosuite group.

Best Wishes
Ming

helena bales

unread,
Mar 20, 2017, 3:13:37 PM3/20/17
to PIT Users
Hello Ming,

Were you able to resolve this issue? I am getting the same error when trying to run Pitest on tests generated using EvoSuite.

Thank you,
Helena
Reply all
Reply to author
Forward
0 new messages