Creating a JUnit Plug-in test manually
TPTP JUnit Plug-in Tests can be created manually or as a result of
importing existing JUnit Plug-in tests outside TPTP into a TPTP JUnit Plug-in Test. They should
be created manually if they are to exploit the TPTP JUnit Plug-in Test behavior
feature.
Note that, before creating a JUnit Plug-in test, a Plug-in project
must exist.
- Select File > New > Other.
- Expand Test. Select TPTP JUnit Plug-in Test.
- Click Next to launch the New JUnit Plug-in Test dialog.
Identify the Source folder (pluginProject/src), the Package
(junit.plugin.samples), and the name to be assigned to the JUnit Plug-in Test source code
(EclipseUiTest).
- Select either 'In the test editor' or 'In the code editor' for the test behavior option. See JUnit Test Suite Editor for a detailed explanation of these options.
- Click Next and provide the test's name and location.
- Click Next and provide a description if required. Click Finish.
- The Confirm Open Editor dialog may appear (see the Window > Preferences... > Test > Open Editor preference), confirming if the new JUnit Plug-in test suite is to be opened in the JUnit Plug-in Test editor.
Note that the second and third pages of the wizard are optional (that is, you can finish the wizard at the first page). Also, the difference between the information requested in page 1 and page 2 is as follows: the first page asks for the name and location of the source code, while the second one asks for the name and location of the TPTP Test (the model). By default, they are identical.