Custom Runners are the primary means of extending JUnit 4. A custom runner can do anything from adding an extra check to the end of each test method, to running tests written in a different test framework (like TestNG) or a different language (like Ruby, or a completely new domain-specific language). Custom runners automatically get tight integration with Eclipse, Ant, and other JUnit-4-aware development tools. In addition, custom runners can make use of JUnit's little-known test prioritization and filtering capabilities.
The talk will first demonstrate JUnit's built-in runners for parameterized data and unit theories (general statements evaluated against specific examples). It will then review custom runners written by third parties, including JMock's runner, the CPSuite runner for automatically finding JUnit test classes, and the JRSpecRunner for running RSpec tests written in Ruby.
Finally, audience members will learn the Custom Runner API as we write together a new custom runner that runs many JUnit tests in parallel threads.
David Saff is a Ph.D. student at the Massachusetts Institute of Technology, researching continuous testing, test factoring, and unit theories, all automated techniques to extend the bug-finding power of simple tests. David's previous research includes work on artificial intelligence, intuitive user interfaces, and computing with small distributed devices. Before joining MIT, David was a software engineer and project manager at Molecular, Inc. In addition to his research activities, David is a developer for the JUnit unit-testing framework, and has contributed to the testing capabilities in the Eclipse IDE.