C# Class Amido.Testing.WebApi.Request.TestRequests

Class which stores a list of request actions and assertions.
Show file Open project: amido/Amido.Testing Class Usage Examples

Public Methods

Method Description
Add ( Func webApiRequest ) : TestRequests

Adds a new WebTestRequest.

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

Adds a retry policy to the WebTestRequest.

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

Adds a retry policy to the WebTestRequest.

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

Adds a retry policy to the WebTestRequest.

TestRequests ( ) : System

Constructs a new TestRequests.

Wait ( int milliseconds, Func webApiRequest ) : TestRequests

Forces the main thread to wait before running the WebTestRequest.

Method Details

Add() public method

Adds a new WebTestRequest.
public Add ( Func webApiRequest ) : TestRequests
webApiRequest Func The action.
return TestRequests

Retry() public method

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.
return TestRequests

Retry() public method

Adds a retry policy to the WebTestRequest.
public Retry ( RetryTestType retryTestType, int value, int maxRetries, int interval, Func webApiRequest ) : TestRequests
retryTestType RetryTestType The .
value int The 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.
return TestRequests

Retry() public method

Adds a retry policy to the WebTestRequest.
public Retry ( RetryTestType retryTestType, string value, int maxRetries, int interval, Func webApiRequest ) : TestRequests
retryTestType RetryTestType The .
value string The 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.
return TestRequests

TestRequests() public method

Constructs a new TestRequests.
public TestRequests ( ) : System
return System

Wait() public method

Forces the main thread to wait before running the WebTestRequest.
public Wait ( int milliseconds, Func webApiRequest ) : TestRequests
milliseconds int The number of milliseconds to wait before proceeding with the .
webApiRequest Func The action.
return TestRequests