Java Reference
In-Depth Information
Figure 7.1 Use the Run/Debug Configurations panel to build one-click
JUnit launch targets.
Selecting a test case to run
As with the other execution target types, the JU nit tab in the Run/Debug Configu-
rations dialog lets you select a Java class that will become the target of this con-
figuration. In this case, however, you are selecting a test case rather than an
executable class. You can choose any test class in your Classpath— IDEA will even
find classes for you and present an appropriately filtered list. Click the browse but-
ton next to the Class field to select the class by name, or navigate through your
project tree. The list is filtered to include only JU nit tests—only classes that extend
junit.framework.TestCase appear.
Select the test case you want to run from the class browser. You can name your
test configuration whatever you wish; this is an arbitrary label for use in the Run
menu. You also have the option to expand your selection to include all the test
cases in a particular package or narrow it to a single method of your test. If you
select the Te s t M e t h o d radio button option, an additional field appears, allowing
 
Search WWH ::




Custom Search