public void compareDefaultConstructor() { analyseMoodFactory <analyseMood> mood = new analyseMoodFactory <analyseMood>(); ConstructorInfo constructor = mood.defaultConstructor(); object obj_compare = mood.GetInstance("analyseMood", constructor); Assert.IsInstanceOf(typeof(analyseMood3), obj_compare); }
public void reflectionNoSuchMethoEception() { try { analyseMoodFactory <analyseMood> mood = new analyseMoodFactory <analyseMood>(); ConstructorInfo constructor = mood.defaultConstructor(); object obj_compare = mood.GetInstance("analyseMood", constructor); } catch (analyseMoodException e) { Assert.AreEqual(analyseMoodException.Exception_Type.No_Such_Method_Exception, e.ex_ty); } }