예제 #1
0
        public void ConvertTest_BadClass()
        {
            var target = new PresetNameConverter()
            {
                DefaltName = "Default",
            };

            target.Convert("BadString", null, null, null);
        }
예제 #2
0
        public void ConvertTest_Null()
        {
            var target = new PresetNameConverter()
            {
                DefaltName = "Default",
            };

            var result = target.Convert(null, null, null, null);

            Assert.AreEqual("Default", result);
        }
예제 #3
0
        public void ConvertTest_NotNull()
        {
            var input = new PresetInfo()
            {
                Name = "Name",
            };
            var target = new PresetNameConverter()
            {
                DefaltName = "Default",
            };

            var result = target.Convert(input, null, null, null);

            Assert.AreEqual("Name", result);
        }