Eclipse plug-in and Rich Client Platform developers face unique challenges in structuring and executing unit tests. In a new article on RCP Qucikstart, Patrick Paulin suggests an approach to unit testing based on Eclipse fragments that can help overcome these challenges. If you find yourself frustrated with your current plug-in testing options, read on! Paulin goes on to examine different options such as placing all code in a single plug-in, placing test code in a separate plug-in, placing test code in a fragment, and so on.
Paulin concludes by saying that, "Overall, however, I’ve found that the benefits of fragment based unit testing far outweigh the disadvantages. If you are satisfied with the more traditional approaches to unit testing plug-ins, then by all means keep doing what you’re doing. But if you find yourself frustrated with the limitations of these approaches, give fragments a try. You’ll be glad you did!"