|
|
@ -170,6 +170,16 @@ public abstract class AbstractEmbeddedServletContainerFactoryTests {
|
|
|
|
assertThat(this.output.toString()).containsOnlyOnce("started on port");
|
|
|
|
assertThat(this.output.toString()).containsOnlyOnce("started on port");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
|
|
|
|
public void stopCalledTwice() throws Exception {
|
|
|
|
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
|
|
|
|
|
this.container = factory
|
|
|
|
|
|
|
|
.getEmbeddedServletContainer(exampleServletRegistration());
|
|
|
|
|
|
|
|
this.container.start();
|
|
|
|
|
|
|
|
this.container.stop();
|
|
|
|
|
|
|
|
this.container.stop();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
public void emptyServerWhenPortIsMinusOne() throws Exception {
|
|
|
|
public void emptyServerWhenPortIsMinusOne() throws Exception {
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
@ -311,16 +321,6 @@ public abstract class AbstractEmbeddedServletContainerFactoryTests {
|
|
|
|
getFactory().setContextPath("/");
|
|
|
|
getFactory().setContextPath("/");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
|
|
|
|
public void doubleStop() throws Exception {
|
|
|
|
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
|
|
|
|
|
this.container = factory
|
|
|
|
|
|
|
|
.getEmbeddedServletContainer(exampleServletRegistration());
|
|
|
|
|
|
|
|
this.container.start();
|
|
|
|
|
|
|
|
this.container.stop();
|
|
|
|
|
|
|
|
this.container.stop();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
public void multipleConfigurations() throws Exception {
|
|
|
|
public void multipleConfigurations() throws Exception {
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
|
AbstractEmbeddedServletContainerFactory factory = getFactory();
|
|
|
|