public void testBuildImplementationClassImproperMethod()
{
Location l = newLocation();
MockControl factoryControl = newControl(ClassFactory.class);
ClassFactory factory = (ClassFactory) factoryControl.getMock();
MockControl cfc = newControl(ClassFab.class);
ClassFab cf = (ClassFab) cfc.getMock();
MethodFab mf = (MethodFab) newMock(MethodFab.class);
MockControl fpc = newControl(ServiceImplementationFactoryParameters.class);
ServiceImplementationFactoryParameters fp = (ServiceImplementationFactoryParameters) fpc
.getMock();
ErrorLog log = (ErrorLog) newMock(ErrorLog.class);
fp.getServiceInterface();
fpc.setReturnValue(Runnable.class);
factory.newClass("NewClass", Object.class);
factoryControl.setReturnValue(cf);
cf.addInterface(Runnable.class);
cf.addField("_registry", StrategyRegistry.class);