I wrote up a page on how to write unit tests after the Spring injection framework is in. Please see here.
https://cwiki.apache.org/confluence/display/CLOUDSTACK/Unit+Testing+with+JUnit+and+Spring We also need help in javelin to finish converting the unit tests over to this format. If you can help, let me know. Thanks. --Alex