public void Should_Add_An_Ingredient_Successfully()
        {
            var shoppingcart = new NewShoppingCartViewModel();

            shoppingcart.CartRefCookie = "123fdfds";
            shoppingcart.Recipes       = new List <Guid>()
            {
                Guid.Parse("ca505ba2-f4b5-42d8-28b6-08d62939ae3c"),
                Guid.Parse("4be82ff5-93aa-428e-28a5-08d62939f7a2"),
                Guid.Parse("2d46b9e6-8e1d-4e64-28a6-08d62939f7a2")
            };

            var request = new AddShoppingCartRequest()
            {
                model = shoppingcart
            };
            var response = _shoppingCartService.AddShoppingCarts(request);
        }
 public ApiResponse <ShoppingCartViewModel> AddRecipe([FromBody] NewShoppingCartViewModel model)
 {
     try
     {
         return(ApiResponse <ShoppingCartViewModel> .CreateResponse(true, "", _shoppingCartService.AddShoppingCarts(new Services.Message.AddShoppingCartRequest()
         {
             model = model
         }).cart));
     }
     catch (BusinessRuleException ex)
     {
         return(ApiResponse <ShoppingCartViewModel> .CreateResponse(false, ex.Message, null, rules : ex.brokenRules, code : HttpStatusCode.BadRequest));
     }
     catch (Exception ex)
     {
         Console.Write(ex);
         return(ApiResponse <ShoppingCartViewModel> .CreateResponse(false, "An unexpected error occured.", null, code : HttpStatusCode.InternalServerError));
     }
 }