I am working on generating test case for Java unit (i.e. method). My output is in form of a Java test method, just like
public void testToInt() {
assertEquals(0, NumberUtils.toInt("0"));
assertEquals(1, NumberUtils.toInt("1"));
assertEquals(2, NumberUtils.toInt("2"));
assertEquals(3, NumberUtils.toInt("3"));
assertEquals(4, NumberUtils.toInt("4"));
assertEquals(5, NumberUtils.toInt("5"));
assertEquals(6, NumberUtils.toInt("6"));
assertEquals(7, NumberUtils.toInt("7"));
assertEquals(8, NumberUtils.toInt("8"));
assertEquals(9, NumberUtils.toInt("9"));
}
Now I need to wrap the test method so that it can be used in defects4j.
The folloing is result after wrapping.
How can I realized it wisely?
Thanks for attention.
By the way, I am not familar with evosuite. But it seems that the result comes from it.
My mentor recommend me to make clear the source code of command gen_test in defects4j.But I am not a perl programmer. source code of command gen_test So I give up the road. Should I learn evosuite from scratch? Is there any method easier?