The module supports some aspects of JUnit-based testing.
There is no client API.
There is a support API (SPI) for a project-type-specific implementation
org.netbeans.modules.junit.plugin This SPI describes services provided by the custom JUnit support plugin which are not desribed by the existing public SPI (
UnitTestForSourceQuery). This SPI
represents an additional source of information for the JUnit module
and allows a custom test-skeleton generator to be plugged.
The object implementing the
is taken by the JUnit module from the current project's lookup,
the same way as the
See the diagram:
Introduced new SPI - abstract class
JUnitPlugin (with a nested
CreateTestParam and a nested final class
Introduced to allow non-J2SE projects to plug in their own implementation
of JUnit support, i.e.:
The SPI allows to plug a project-type-specific implementation of JUnit support into NetBeans. The current NetBeans implementation only supports JUnit on J2SE project types. The SPI describes services provided by the custom JUnit support plugin.
The functionality to be plugged in comprises:
For navigation, the plugin defines mapping between source classes and
the corresponding test classes (both directions). Thus it provides
an additional information to the information provides by
For generation of test skeletons, the plugin actually defines the whole test skeleton generator - it generates one or more test files for a given source file.
The sources for the module are in the NetBeans Mercurial repositories.
Read more about the implementation in the answers to architecture questions.
Built on June 18 2013. | Portions Copyright 1997-2013 Oracle. All rights reserved.