IntelliJ IDEA 13.1 Web Help

To create stub test methods in JUnit test classes, you can use the IntelliJ IDEA code generation feature.

Note

To create a test class with a complete set of test methods and fixtures, use the Create Test intention action.

Creating a stub test method in a JUnit test class
  1. Open the corresponding JUnit test class in the editor.
  2. Place the cursor where you want a new test method to be generated.
  3. Press Alt+InsertAlt+InsertAlt+InsertAlt+InsertAlt+InsertAlt+InsertCtrl+N or Alt+InsertAlt+InsertAlt+InsertCommand N or Control EnterControl N or Control EnterCommand N or Control Enter and select Test Method from the Generate menu.

See Also

Concepts:

Procedures:

Web Resources: