Monday, May 16, 2011

Testing a GWT/Mvp4g application in the JVM

I developped a client for a logistics system using Mvp4g and GWT. The system has technically quite complex integration tests, where a J5EE based core application serves multiple WPF thick clients and GWT web clients. I use the same infrastructure to test the overall performance of the system. It might not have been the best decision, but I didn't want to use Selenium or HtmlUnit at that time, so I chose to instantiate my GWT application in the JVM, using mock views.

The post in my blog discusses the solutions that were needed to make in-JVM testing possible.
  • Implementing a simple EventBus using relfection and dynamic proxies.
  • Invoking GWT RPC services from the JVM.
  • Handling GWT i18n in the JVM.
  • Adding performance logging capabilities to RPC invocations.