Code Robo
Virtual Service
Comparator
Tester
Converter
Utility
Java Code Complience
Validator
Formatter
EncoderDecoder
Generate JUnit Test Cases
       Talk to EasyAssistant

For any Java/J2EE project we wirte lot many java classes. To do the unit test of those Java classes normally we used to write JUnit test cases. Here we have online Junit Tool to generate JUnit test cases for each java class.. Generating Junit testcases common requirement in any Java/J2EE development project.Take Java Code as input and generate JUnit test class as output.

This tool supports following important features:
  • Test suites
  • Test runners
  • JUnit classes
  • Supports both JUnitVersion 4.0 and Version 5.0
Gnerated code uses following classes:
  • Assert - Contains assert methods.
  • TestCase - defines the fixture to run multiple tests.
  • TestResult - Collect the results of executing a test case.
Java Code.(* Required): It is required.
Ignore Private Methods JUnit Version :        JUnit 4.0 JUnit 5.0


How It Works:
First format the java source code and then parse it. Extract the tokens. Generate JUnit class and add a test method for each non-private methods. Equate the actual and expeted value. If expected and actual value does not match, it fail the test cases. It generate code to handle exception and fail the test case if there is any exception.
. Input Parameters are:
  1. Java Code - Which is used to generate the JUnit test cases
  2. Generate Test Cases For Private Methods - Generate unit test cases for private method
  3. Click on the button 'Generate JUnit '

Post Your Comment:
Name :
Email ( Optional) :
Comments / Suggestion (* Required) It is required: :
: