Exemple #1
0
        public void IsValueType_PrimitiveTypeNameProvided_TrueReturned()
        {
            TestConverter converter = new TestConverter();

            bool result = converter.TestIsValueType(typeof(int).AssemblyQualifiedName);

            Assert.IsTrue(result);
        }
Exemple #2
0
        public void IsValueType_EnumTypeProvided_TrueReturned()
        {
            TestConverter converter = new TestConverter();

            bool result = converter.TestIsValueType(typeof(StringComparison));

            Assert.IsTrue(result);
        }
Exemple #3
0
        public void IsValueType_ReferenceTypeProvided_FalseReturned()
        {
            TestConverter converter = new TestConverter();

            bool result = converter.TestIsValueType(typeof(IList));

            Assert.IsFalse(result);
        }
Exemple #4
0
        public void IsValueType_DateTimeTypeProvided_TrueReturned()
        {
            TestConverter converter = new TestConverter();

            bool result = converter.TestIsValueType(typeof(DateTime));

            Assert.IsTrue(result);
        }
Exemple #5
0
        public void IsValueType_NullProvided_FalseReturned()
        {
            TestConverter converter = new TestConverter();

            bool result = converter.TestIsValueType(null as Type);

            Assert.IsFalse(result);
        }