EasyMock.expect(rme.getEndpoint(ProtocolVariation.RM10WSA200408)).andReturn(e);
EndpointInfo ei = control.createMock(EndpointInfo.class);
EasyMock.expect(e.getEndpointInfo()).andReturn(ei);
Bus bus = control.createMock(Bus.class);
EasyMock.expect(manager.getBus()).andReturn(bus).times(2);
PolicyEngine pe = control.createMock(PolicyEngine.class);
EasyMock.expect(bus.getExtension(PolicyEngine.class)).andReturn(pe);
EasyMock.expect(pe.isEnabled()).andReturn(true);
PolicyInterceptorProviderRegistry reg = control.createMock(PolicyInterceptorProviderRegistry.class);
EasyMock.expect(bus.getExtension(PolicyInterceptorProviderRegistry.class)).andReturn(reg);
EndpointInfo aei = control.createMock(EndpointInfo.class);
EasyMock.expect(ae.getEndpointInfo()).andReturn(aei);
EndpointPolicy epi = control.createMock(EndpointPolicy.class);
EasyMock.expect(pe.getServerEndpointPolicy(aei, null)).andReturn(epi);
EasyMock.expect(epi.getChosenAlternative()).andReturn(new ArrayList<Assertion>());
pe.setServerEndpointPolicy(ei, epi);
EasyMock.expectLastCall();
BindingInfo bi = control.createMock(BindingInfo.class);
EasyMock.expect(ei.getBinding()).andReturn(bi);
BindingOperationInfo boi = control.createMock(BindingOperationInfo.class);
EasyMock.expect(bi.getOperations()).andReturn(Collections.singletonList(boi));
pe.setEffectiveServerRequestPolicy(EasyMock.eq(ei), EasyMock.eq(boi), EasyMock
.isA(EffectivePolicy.class));
EasyMock.expectLastCall();
pe.setEffectiveServerResponsePolicy(EasyMock.eq(ei), EasyMock.eq(boi), EasyMock
.isA(EffectivePolicy.class));
EasyMock.expectLastCall();
pe.setEffectiveClientRequestPolicy(EasyMock.eq(ei), EasyMock.eq(boi), EasyMock
.isA(EffectivePolicy.class));
EasyMock.expectLastCall();
pe.setEffectiveClientResponsePolicy(EasyMock.eq(ei), EasyMock.eq(boi), EasyMock
.isA(EffectivePolicy.class));
EasyMock.expectLastCall();
control.replay();
rme.setPolicies();
}