public void TestConstructOptional() { PocoOptConstructor tCast = Dynamic.InvokeConstructor(typeof(PocoOptConstructor), new InvokeArg("three", "3")); Assert.AreEqual("-1", tCast.One); Assert.AreEqual("-2", tCast.Two); Assert.AreEqual("3", tCast.Three); }
public void TestConstructOptional() { PocoOptConstructor tCast = Impromptu.InvokeConstructor(typeof(PocoOptConstructor), "3".WithArgumentName("three")); Assert.AreEqual("-1", tCast.One); Assert.AreEqual("-2", tCast.Two); Assert.AreEqual("3", tCast.Three); }
public void TestConstructOptional() { var argname = InvokeArg.Create; PocoOptConstructor tCast = Dynamic.InvokeConstructor(typeof(PocoOptConstructor), argname("three", "3")); Assert.AreEqual("-1", tCast.One); Assert.AreEqual("-2", tCast.Two); Assert.AreEqual("3", tCast.Three); }