codahale/dropwizard — pull request #266 by tomakehurst (2013-02-17 21:46:51+00:00)
Title: A JUnit Rule to start and stop your service

On both systems I've built with Dropwizard I've ended up building a mechanism for starting and stopping the app from JUnit to allow in-memory acceptance testing.

This is slightly awkward to do currently due to the fact that the server command blocks (on server.join()) after startup and provides no hook for getting at the server to stop it. This patch provides a JUnit Rule along with some changes to a couple of core classes to resolve the above issues.