예제 #1
0
        public void GenericTypeCanGetTheGenericArgumentName()
        {
            var helloCat = new SayHello <Cat> ();

            //Assert.AreEqual (FILL_ME_IN, helloCat.HelloMessage ());
            Assert.AreEqual("Hola Cat", helloCat.HelloMessage());
        }
예제 #2
0
        public void GenericTypeCanBeUsedWithAnyTypeEvenPrimitives()
        {
            var helloInt = new SayHello <int> ();

            //Assert.AreEqual (FILL_ME_IN, helloInt.HelloMessage ());
            Assert.AreEqual("Hola " + typeof(int).ToString().Split('.').GetValue(1),
                            helloInt.HelloMessage());
        }
예제 #3
0
        public void GenericTypeCanBeUsedWithAnyTypeEvenPrimitives()
        {
            var helloInt = new SayHello <int> ();

            Assert.AreEqual("Hello Int32", helloInt.HelloMessage());
        }