/// <summary>
        /// Specifies NumberOfTimes(2) to the IRepeatConfiguration{TFake}.
        /// </summary>
        /// <typeparam name="TFake">The type of fake object.</typeparam>
        /// <param name="configuration">The configuration to set repeat 2 to.</param>
        public static void Twice(this IRepeatConfiguration configuration)
        {
            Guard.IsNotNull(configuration, "configuration");

            configuration.NumberOfTimes(2);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Specifies NumberOfTimes(2) to the repeat configuration.
        /// </summary>
        /// <typeparam name="TInterface">The type of configuration interface to return.</typeparam>
        /// <param name="configuration">The configuration to set repeat 2 to.</param>
        /// <returns>A configuration object that lets you define the subsequent behavior.</returns>
        public static IThenConfiguration <TInterface> Twice <TInterface>(this IRepeatConfiguration <TInterface> configuration)
        {
            Guard.AgainstNull(configuration, nameof(configuration));

            return(configuration.NumberOfTimes(2));
        }
 /// <summary>
 /// Specifies NumberOfTimes(1) to the IRepeatConfiguration{TFake}.
 /// </summary>
 /// <typeparam name="TFake">The type of fake object.</typeparam>
 /// <param name="configuration">The configuration to set repeat 1 to.</param>
 public static void Once <TFake>(this IRepeatConfiguration <TFake> configuration)
 {
     Guard.IsNotNull(configuration, "configuration");
     configuration.NumberOfTimes(1);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Specifies NumberOfTimes(1) to the IRepeatConfiguration{TFake}.
 /// </summary>
 /// <param name="configuration">The configuration to set repeat 1 to.</param>
 public static void Once(this IRepeatConfiguration configuration)
 {
     Guard.AgainstNull(configuration, "configuration");
     configuration.NumberOfTimes(1);
 }
Ejemplo n.º 5
0
        /// <summary>
        /// Specifies NumberOfTimes(2) to the repeat configuration.
        /// </summary>
        /// <param name="configuration">The configuration to set repeat 2 to.</param>
        public static void Twice(this IRepeatConfiguration configuration)
        {
            Guard.AgainstNull(configuration, nameof(configuration));

            configuration.NumberOfTimes(2);
        }