예제 #1
0
        public void AddDockerSecrets(string configKey, string expected)
        {
            var configurationBuilder = new TestConfigurationBuilder();

            Assert.Empty(configurationBuilder.Sources);

            configurationBuilder
            .AddDockerSecrets();

            Assert.NotEmpty(configurationBuilder.Sources);

            var configuration = configurationBuilder.Build();

            var actual = configuration.GetValue <string>(configKey);

            Assert.NotNull(actual);
            Assert.Equal(expected, actual);
        }