예제 #1
0
        public void GetConnectionStringShouldReturnStringWhereNullPropertiesIgnored()
        {
            IConnectionSettings mockSettings = new MockConnectionSettings
            {
                PropertyOne   = "one",
                PropertyThree = 3
            };

            var connectionString = mockSettings.BuildConnectionString();

            Assert.Equal("PropertyOne=one;PropertyThree=3;", connectionString);
        }
예제 #2
0
        public void GetConnectionStringShouldReturnStringWithAllPropertiesWithValue()
        {
            IConnectionSettings mockSettings = new MockConnectionSettings
            {
                PropertyOne   = "one",
                PropertyTwo   = true,
                PropertyThree = 3
            };

            var connectionString = mockSettings.BuildConnectionString();

            Assert.Equal("PropertyOne=one;PropertyTwo=True;PropertyThree=3;", connectionString);
        }