In Artima SuiteRunner's API contracts, "test" is used abstractly. A test method is one kind of test, but not the only kind. Executing test methods, as performed by Suite's implementation of execute, is one way to execute tests -- but not the only way. To execute tests in a different way, Suite subclasses can override execute. When execute is invoked on such a Suite subclass, its own execute implementation can execute tests in a custom way.
This article shows an example of a Suite subclass whose execute method:
- Reads in a file, written in a simple custom scripting language, that contains test commands - Interprets the commands in the file, and executes the requested tests - Invokes execute on each sub-Suite