Message m = new MessageImpl();
Exchange e = new ExchangeImpl();
e.put(Service.class, new JAXRSServiceImpl(cris));
m.setExchange(e);
control.reset();
ServletDestination d = control.createMock(ServletDestination.class);
EndpointInfo epr = new EndpointInfo();
epr.setAddress(baseAddress);
d.getEndpointInfo();
EasyMock.expectLastCall().andReturn(epr).anyTimes();
Endpoint endpoint = new EndpointImpl(null, null, epr);
e.put(Endpoint.class, endpoint);
endpoint.put(ServerProviderFactory.class.getName(), ServerProviderFactory.getInstance());