public void UninterestingNameQueriesContext(
        ErrorResponse err,
        ISpecimenContext context,
        ErrorResponseParameterBuilder sut)
    {
        context.MockToReturn(err);
        var           param = typeof(NonInterestingClass).Methods().First().GetParameters().First();
        ErrorResponse resp  = (ErrorResponse)sut.Create(param, context);

        context.ShouldHaveCreated <ErrorResponse>();
        resp.Should().Be(err);
    }
 public void FailDoesNotReturnException(
     string errString,
     ISpecimenContext context,
     ErrorResponseParameterBuilder sut)
 {
     context.MockToReturn(errString);
     foreach (var method in typeof(Fails).Methods())
     {
         var param = method.GetParameters().First();
         context.ClearReceivedCalls();
         ErrorResponse resp = (ErrorResponse)sut.Create(param, context);
         resp.Exception.Should().BeNull();
     }
 }
 public void FailReturnsFail(
     string errString,
     ISpecimenContext context,
     ErrorResponseParameterBuilder sut)
 {
     context.MockToReturn(errString);
     foreach (var method in typeof(Fails).Methods())
     {
         var param = method.GetParameters().First();
         context.ClearReceivedCalls();
         ErrorResponse resp = (ErrorResponse)sut.Create(param, context);
         resp.Succeeded.Should().BeFalse();
         resp.Reason.Should().Be(errString);
     }
 }