Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Java Unit Testing Completeness Indicator Tool? [closed]

I am talking about the real 'Test Completeness', not the traditional 'Code Coverage',because Code Coverage is not very helpful when people start asking for more accurate estimations.

And by 'Test Completeness' I mean that (virtually) ALL possible usages of a function are covered, including Border conditions of the arguments, etc.

There is another Stackoverflow thread discussing this topic, but no java tool is mentioned in it. Is there a good measure of completeness of Unit tests

Is there such as tool that can take a look at the current JUnit Tests and tell me approximately the percentage of completeness?

Thanks.

like image 388
Victor Avatar asked Oct 20 '22 23:10

Victor


2 Answers

Have a search for Mutation Testing. An example is http://pitest.org/. Basically it changes your code and reruns the tests (like x == true changes to x == false), if your tests don't fail when the change is made then your tests are insufficient.

like image 122
TofuBeer Avatar answered Nov 15 '22 04:11

TofuBeer


I think you are referring to a "white-box" tester. There is a commercial program called JTest but I've never used it myself.

like image 36
dkatzel Avatar answered Nov 15 '22 03:11

dkatzel