IRepeat

Allows to specified the number of times a method is called.

Summary
Allows to specified the number of times a method is called.
The method will repeat twice
The method will repeat once.
Repeat the method any number of times.
Repeat the method the specified number of time between min & max.
Set the exact number of times this method can repeat.
This method must not appear in the replay state.

Functions

Twice

IMethodOptions Twice()

The method will repeat twice

Once

IMethodOptions Once()

The method will repeat once.

note

This is the default behaviour.

AtLeastOnce

IMethodOptions AtLeastOnce()

Any

IMethodOptions Any()

Repeat the method any number of times.

note

This has special affects in that this method would now ignore orderring.

Times

IMethodOptions Times(int min,
int max)

Repeat the method the specified number of time between min & max.

Params

  • min - The minimum number of times the method can repeat
  • max - The maximum number of times the method can repeat

Times

IMethodOptions Times(int count)

Set the exact number of times this method can repeat.

Never

IMethodOptions Never()

This method must not appear in the replay state.

note

This has special affects in that this method would now ignore orderring.

IMethodOptions Twice()
The method will repeat twice
IMethodOptions Once()
The method will repeat once.
IMethodOptions AtLeastOnce()
IMethodOptions Any()
Repeat the method any number of times.
IMethodOptions Times(int min,
int max)
Repeat the method the specified number of time between min & max.
IMethodOptions Never()
This method must not appear in the replay state.