コード例 #1
0
 /// <summary>
 /// Register a mocked type and arrange a method on it.
 /// </summary>
 /// <typeparam name="TDependency">The type of mock to register.</typeparam>
 /// <param name="container">The mocking container.</param>
 /// <param name="expression">The method to arrange.</param>
 /// <returns>Fluent interface to further configure the behavior of this arrangement.</returns>
 public static ActionExpectation Arrange <TDependency>(this IUnityContainer container, Expression <Action <TDependency> > expression)
 {
     return(container.Arrange(null, expression));
 }
コード例 #2
0
 /// <summary>
 /// Register a mocked type and arrange a method on it.
 /// </summary>
 /// <typeparam name="TDependency">The type of mock to register.</typeparam>
 /// <param name="container">The mocking container.</param>
 /// <param name="expression">The method to arrange.</param>
 /// <returns>Fluent interface to further configure the behavior of this arrangement.</returns>
 public static FuncExpectation <object> Arrange <TDependency>(this IUnityContainer container, Expression <Func <TDependency, object> > expression)
 {
     return(container.Arrange(null, expression));
 }