public void MakeEmptyStringsNull_ObjectContainsEmptyStringInRoot_ConvertsToNull()
        {
            var simpleObject = new SimpleObject { MyString = string.Empty };

            var result = simpleObject.MakeEmptyStringsNull();

            Assert.Null(result.MyString);
        }
        public void MakeEmptyStringsNull_ObjectContainsNonEmptyStringInRoot_DoesNotChangeXml()
        {
            var myString = "something";
            var simpleObject = new SimpleObject { MyString = myString };

            var result = simpleObject.MakeEmptyStringsNull();

            Assert.Equal(myString, result.MyString);
        }
Exemplo n.º 3
0
        public void MakeEmptyStringsNull_ObjectContainsEmptyStringInRoot_ConvertsToNull()
        {
            var simpleObject = new SimpleObject {
                MyString = string.Empty
            };

            var result = simpleObject.MakeEmptyStringsNull();

            Assert.Null(result.MyString);
        }
Exemplo n.º 4
0
        public void MakeEmptyStringsNull_ObjectContainsNonEmptyStringInRoot_DoesNotChangeXml()
        {
            var myString     = "something";
            var simpleObject = new SimpleObject {
                MyString = myString
            };

            var result = simpleObject.MakeEmptyStringsNull();

            Assert.Equal(myString, result.MyString);
        }