예제 #1
0
        public static async Task <TResponse> InvokeWithContentAndGetResponseAs <TResponse>(this GitHubMonitorFunction function, SampleCallbackData data)
            where TResponse : IActionResult
        {
            var result = await function.Invoke(req => configureRequest(req, data));

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

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