예제 #1
0
        public void Test()
        {
            // If you got an 'Invalid executable format' exception here
            // you need to install .Net Framework 2.0 SP1 or later.
            //
            TestObject t = TypeAccessor <TestObject> .CreateInstance();

            Assert.AreEqual("123", t.GetValue("123"));
            Assert.AreEqual(0, t.Abstract(123));
            Assert.AreEqual(0, t.Abstract2(123));
            Assert.AreEqual(0, t.Abstract3(123));

            // Throws ArgumentNullException
            //
            t.GetValue <string>(null);
        }