Example #1
0
        public void Invoke_GenericMethod()
        {
            string motif        = "StephanieDeMonaco";
            string nameOfMethod = "GetBaseTYpe";
            object type         = typeof(GenericType <>);
            Type   result       = Exercices_Lvl_3.Invoke_GenericMethod(typeof(GenericType <>), motif, nameOfMethod);

            Assert.IsTrue(result.Name == "object");
        }
Example #2
0
        public void instanciate_Generic_Type()
        {
            object o = Exercices_Lvl_3.instanciate_GenericType(typeof(GenericType <>), typeof(int));

            Assert.IsTrue(o is GenericType <int>);
        }