Exemplo n.º 1
0
        public void ProductSpecificationAttributeController_EditPost_CallsUpdateOptionOnTheManager()
        {
            var controller = GetProductSpecificationAttributeController();
            var option     = new ProductSpecificationAttribute();

            var editPost = controller.Edit_POST(option);

            A.CallTo(() => _productOptionManager.UpdateSpecificationAttribute(option)).MustHaveHappened();
        }
Exemplo n.º 2
0
 public ActionResult Edit_POST(ProductSpecificationAttribute option)
 {
     if (ModelState.IsValid)
     {
         _productOptionManager.UpdateSpecificationAttribute(option);
         return(RedirectToAction("Index"));
     }
     else
     {
         return(PartialView(option));
     }
 }