* @since 1.1
*/
public void testGetServiceMatchesPublicOnly()
{
MockControl spc1 = newControl(ServicePoint.class);
ServicePoint sp1 = (ServicePoint) spc1.getMock();
MockControl spc2 = newControl(ServicePoint.class);
ServicePoint sp2 = (ServicePoint) spc2.getMock();
ClassFactory service = (ClassFactory) newMock(ClassFactory.class);
// Training
sp1.getExtensionPointId();
spc1.setReturnValue("foo.Private");
sp1.getServiceInterfaceClassName();
spc1.setReturnValue(ClassFactory.class.getName());
sp2.getExtensionPointId();
spc2.setReturnValue("foo.Public");
sp2.getServiceInterfaceClassName();
spc2.setReturnValue(ClassFactory.class.getName());
sp1.visibleToModule(null);
spc1.setReturnValue(false);
sp2.visibleToModule(null);
spc2.setReturnValue(true);
sp2.getService(ClassFactory.class);
spc2.setReturnValue(service);
replayControls();
RegistryInfrastructureImpl r = new RegistryInfrastructureImpl(null, null);