public void UpdateTest() { Rating rating = RatingManager.LoadByID(1); rating.Description = "Oo"; Assert.IsTrue(RatingManager.Update(rating) > 0); }
// GET: Rating/Edit/5 public ActionResult Edit(int id) { if (Authenticate.IsAuthenticated()) { ViewBag.Title = "Edit"; var rating = RatingManager.LoadByID(id); return(View(rating)); } else { return(RedirectToAction("Login", "User", new { returnurl = HttpContext.Request.Url })); } }