示例#1
0
        public void ToString_OfNullSet_ShouldReturnTypeAndNullMark()
        {
            var byValue = new SetByValue <int>(null, new Options <int>(false, null));

            var result = byValue.ToString();

            Assert.AreEqual("<null> of Int32", result);
        }
示例#2
0
        public void ToString_OfEmptySet_ShouldReturnCountOfSetAndAllItems()
        {
            var byValue = new SetByValue <int>(new HashSet <int> {
            }, new Options <int>(false, null));

            var result = byValue.ToString();

            Assert.AreEqual("0:[]", result);
        }
示例#3
0
        public void ToString_ShouldReturnCountOfSetAndAllItems()
        {
            var byValue = new SetByValue <string>(new HashSet <string> {
                "qwe", "asd"
            }, Options);

            var result = byValue.ToString();

            Assert.AreEqual("2:[qwe,asd]", result);
        }