+1! Thanks for removing the need of 3 files per test! -----Original Message----- From: Alex Huang [mailto:alex.hu...@citrix.com] Sent: Monday, May 06, 2013 8:26 PM To: dev@cloudstack.apache.org Subject: [TIPS] Writing unit tests with Spring injection...
I made an improvement to how we write our unit tests. Before this change, you needed to have three files for every unit test: 1. The unit test itself 2. The xml configuration 3. The java test configuration With this change, you only need the unit test and you can specify the test configuration within the Java class. It mainly got rid of the xml file if you don't want to use it. I've updated the wiki[1]. Please have a read. --Alex [1] https://cwiki.apache.org/confluence/display/CLOUDSTACK/Unit+Testing+with+JUnit+and+Spring