public void SetUp() { _previousConfiguration = ServiceLocationConfiguration.Current; ServiceLocationConfiguration.SetCurrent(null); ResetDefaultServiceLocator(); SafeServiceLocator.BootstrapConfiguration.Reset(); }
private ServiceLocationConfiguration Deserialize(string xmlFragment) { var section = new ServiceLocationConfiguration(); ConfigurationHelper.DeserializeSection(section, xmlFragment); return(section); }
private void ConfigureServiceLocatorProvider(IServiceLocatorProvider serviceLocatorProvider) { var serviceLocationConfiguration = MockRepository.GenerateStub <IServiceLocationConfiguration>(); serviceLocationConfiguration.Stub(stub => stub.CreateServiceLocatorProvider()).Return(serviceLocatorProvider); ServiceLocationConfiguration.SetCurrent(serviceLocationConfiguration); ResetDefaultServiceLocator(); }
public void TearDown() { ServiceLocationConfiguration.SetCurrent(_previousConfiguration); ResetDefaultServiceLocator(); SafeServiceLocator.BootstrapConfiguration.Reset(); }