Automatically generate test code from a class (banks

We have thousands of classes without true unit test coverage. As a special project, we strive to provide reasonable lighting for everyone. One option is to create tests from the source code and use the GenerateTestCases plugin with IJ .

I am exploring other options for mass test creation.

Is it possible to create tests (well, only test patterns) from class files? TestGen4J does this, but the project seems to be inactive. Is there any tool that could help create tests for thousands of classes.

Once such tests are generated, I hope that we will have more incentive to add additional unit tests for existing classes.

+6
source share
2 answers

The Google CodePro Analytix eclipse plugin can automatically generate unit tests for you, and it is actively supported.

+4
source

you can also try netbeans tools, select class tools and right-click / create Junit Test, but its manual and ugly task for thousands of files

+1
source

Source: https://habr.com/ru/post/904175/


All Articles