Amido.Testing.WebApi.Request.TestRequests.Retry C# (CSharp) Метод

Retry() публичный Метод

Adds a retry policy to the WebTestRequest.
public Retry ( RetryTestType retryTestType, Func value, int maxRetries, int interval, Func webApiRequest ) : TestRequests
retryTestType RetryTestType The .
value Func The delegate value to be used in the retry test.
maxRetries int The max number of retries.
interval int The interval in milliseconds between each retry.
webApiRequest Func The action.
Результат TestRequests
        public TestRequests Retry(RetryTestType retryTestType, Func<string> value, int maxRetries, int interval, Func<WebTestRequest> webApiRequest, params Func<ValidationRule>[] asserts)
        {
            Contract.Requires(maxRetries >= 0, "The max retries cannot be less than 0.");
            Contract.Requires(interval >= 0, "The retry interval cannot be less than 0.");
            Contract.Requires(webApiRequest != null, "The web api request cannot be null.");

            var testRequest = new TestRequest { Request = webApiRequest, Asserts = asserts, RetryTestType = retryTestType, RetryValueDelegate = value, MaxRetries = maxRetries, Interval = interval };
            Requests.Add(testRequest);
            return this;
        }

Same methods

TestRequests::Retry ( RetryTestType retryTestType, int value, int maxRetries, int interval, Func webApiRequest ) : TestRequests
TestRequests::Retry ( RetryTestType retryTestType, string value, int maxRetries, int interval, Func webApiRequest ) : TestRequests