package camelinaction; import org.apache.camel.test.spring.CamelSpringTestSupport; import org.junit.Test; import org.springframework.context.support.AbstractXmlApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; public class GracefulShutdownTest extends CamelSpringTestSupport { @Override public void setUp() throws Exception { deleteDirectory("target/inventory/updates"); super.setUp(); } @Override protected AbstractXmlApplicationContext createApplicationContext() { return new ClassPathXmlApplicationContext("META-INF/spring/camel-route-java.xml"); } @Test public void testShutdown() throws Exception { // see console output for shutdown } }