コード例 #1
0
 /// <summary>
 ///     Introduces a step that returns values from a list one-by-one when read, while passing on any writes to subsequent
 ///     steps. It will also
 ///     pass on reads once the list has been exhausted.
 /// </summary>
 /// <typeparam name="TValue">The type of the property.</typeparam>
 /// <param name="caller">The mock or step to which this 'return' step is added.</param>
 /// <param name="values">The values to be returned one-by-one.</param>
 /// <returns>An <see cref="ICanHaveNextPropertyStep{TValue}" /> that can be used to add further steps.</returns>
 public static ICanHaveNextPropertyStep <TValue> ReturnEach <TValue>(
     this ICanHaveNextPropertyStep <TValue> caller,
     params TValue[] values)
 {
     return(caller.ReturnEach(values.AsEnumerable()));
 }