private void InvokeFuncTest(MethodInfo method) {
     var facet = new ActionInvocationFacetViaMethod(method, null, null, null, null, false);
     Assert.IsNull(facet.ActionDelegate);
     Assert.IsNotNull(facet.GetMethod());
     var parms = method.GetParameters().Select(p => "astring").Cast<object>().ToArray();
     Assert.AreEqual(method.Name, facet.GetMethod().Invoke(new TestDelegateClass(), parms));
 }
 private void DelegateActionTest(MethodInfo method) {
     var facet = new ActionInvocationFacetViaMethod(method, null, null, null, null, false);
     var parms = method.GetParameters().Select(p => "astring").Cast<object>().ToArray();
     Assert.IsNotNull(facet.ActionDelegate, method.Name);
     var testObject = new TestDelegateClass();
     facet.ActionDelegate.Invoke(testObject, parms);
     Assert.AreEqual(method.Name, testObject.ActionCalled);
 }