We have a rather larger Eclipse RCP application and are not sure how to properly test it's plugins.
- For each plugin, there is a test fragment that contains Unit tests.
- For smaller tests, that do not require the RCP Platform running, we simply invoke the "standard" JUnit test runner.
- For tests, that require the RCP Platform, there is the possibility to test it using the JUnit plugin test runner.
- For the JUnit plugin tests, it is possible to define which plugins are loaded when the RCP Platform starts up.
Problem: Running JUnit Plugin Tests takes a lot of time (seconds instead of millicseconds for simple JUnit Test) and resources, since the RCP Platform and all plugins need to start up.
Question: How can I efficiently minimize the plugins that are run for the test? What options do I have to minimize my dependencies to the RCP Platform (such as Preferences Service and Extension Points)? Are there maybe some Mocking libraries or at least some best practices for mocking RCP Platform services?
Right now I cannot imagine to do some decent TDD with the JUnit plugin test runner, it just takes too long to execute these tests.
Any advice and experience on that topic very welcome!