public static async Task <TResponse> InvokeWithContentAndGetResponseAs <TResponse>(this ResultProcessingFunction function, SampleCallbackData data, IDateTimeProvider dateTimeProvider)
            where TResponse : IActionResult
        {
            var result = await function.Invoke(req => configureRequest(req, data, dateTimeProvider));

            Assert.IsInstanceOfType(result, typeof(TResponse));
            return((TResponse)result);
        }
        public static async Task <TResponse> InvokeAndGetResponseAs <TResponse>(this ResultProcessingFunction function, Action <HttpRequest> configureRequest)
            where TResponse : IActionResult
        {
            var result = await function.Invoke(configureRequest);

            Assert.IsInstanceOfType(result, typeof(TResponse));
            return((TResponse)result);
        }