Search in sources :

Example 1 with DummyServer

use of org.apache.cxf.endpoint.DummyServer in project cxf by apache.

the class ServerRegistryImpTest method testServerRegistryPreShutdown.

@Test
public void testServerRegistryPreShutdown() {
    ServerRegistryImpl serverRegistryImpl = new ServerRegistryImpl();
    Server server = new DummyServer(serverRegistryImpl);
    server.start();
    assertEquals("The serverList should have one service", serverRegistryImpl.serversList.size(), 1);
    serverRegistryImpl.preShutdown();
    assertEquals("The serverList should be clear ", serverRegistryImpl.serversList.size(), 0);
    serverRegistryImpl.postShutdown();
    assertEquals("The serverList should be clear ", serverRegistryImpl.serversList.size(), 0);
}
Also used : Server(org.apache.cxf.endpoint.Server) DummyServer(org.apache.cxf.endpoint.DummyServer) DummyServer(org.apache.cxf.endpoint.DummyServer) Test(org.junit.Test)

Aggregations

DummyServer (org.apache.cxf.endpoint.DummyServer)1 Server (org.apache.cxf.endpoint.Server)1 Test (org.junit.Test)1