private void Given_a_switch_factory_with_a_switch_initialised() { _switcher = Substitute.For <IProvideSwitches>(); _switchProviderFactory = Substitute.For <ISwitchProviderFactory>(); _switchProviderFactory.Create().Returns(_switcher); Features.Initialize(_switchProviderFactory); }
public static bool IsAvailable(string featureName) { switchProvider = switchProviderFactory.Create(); switchProvider.ReadConfiguration(); return(switchProvider.IsAvailable(featureName)); }
private void Given_a_switch_factory_with_a_switch_initialised() { _switcher = Substitute.For<IProvideSwitches>(); _switchProviderFactory = Substitute.For<ISwitchProviderFactory>(); _switchProviderFactory.Create().Returns(_switcher); Features.Initialize(_switchProviderFactory); }