Exemplo n.º 1
0
        public void ErrorWhenConnectionStringNameConfiguredInAppSettingsButNoEntryInConnectionStrings()
        {
            var sut = new NameDoesNotExistInConnectionStringsSqlServerToggle();

            var ex = Assert.Throws <ToggleConfigurationError>(() => sut.FeatureEnabled);

            ex.Message.ShouldBe("No entry named 'MissingName' exists in <connectionStrings>.");
        }
        public void ErrorWhenConnectionStringNameConfiguredInAppSettingsButNoEntryInConnectionStrings()
        {
            var sut = new NameDoesNotExistInConnectionStringsSqlServerToggle();

            var ex = Assert.Throws<ToggleConfigurationError>(() => sut.FeatureEnabled);

            ex.Message.ShouldBe("No entry named 'MissingName' exists in <connectionStrings>.");
        }