Пример #1
0
 public void Init()
 {
     myRecipeDataAdapter   = NSubstitute.Substitute.For <IRecipeDataAdapter>();
     myProductAdapter      = NSubstitute.Substitute.For <IProductDataAdapter>();
     myShoppingListService = NSubstitute.Substitute.For <IShoppingListService>();
     myService             = new RecipeService(myRecipeDataAdapter, myProductAdapter, myShoppingListService);
 }
Пример #2
0
        public void Initialize()
        {
            myShoopingListAdapter = Substitute.For <IShoppingListDataAdapter>();
            myProductAdapter      = Substitute.For <IProductDataAdapter>();
            myRecipeAdapter       = Substitute.For <IRecipeDataAdapter>();

            myService = new ShoppingListService(myShoopingListAdapter, myProductAdapter, myRecipeAdapter);
        }
Пример #3
0
 public void init()
 {
     myRecipeAdpater  = Substitute.For <IRecipeDataAdapter>();
     myProductAdpater = Substitute.For <IProductDataAdapter>();
     recipeService    = new RecipeService(myRecipeAdpater, myProductAdpater);
 }
Пример #4
0
 public ShoppingListService(IShoppingListDataAdapter shoppingListDataAdapter, IProductDataAdapter productDataAdapter, IRecipeDataAdapter recipeDataAdapter)
 {
     myShoppingListDataAdapter = shoppingListDataAdapter;
     myProductDataAdapter      = productDataAdapter;
     this.recipeDataAdapter    = recipeDataAdapter;
 }
Пример #5
0
 public RecipeService(IRecipeDataAdapter recipeAdapter, IProductDataAdapter productDataAdapter, IShoppingListService shoppingListService)
 {
     this.recipeAdapter         = recipeAdapter;
     this.productDataAdapter    = productDataAdapter;
     this.myShoppingListService = shoppingListService;
 }