示例#1
0
 public void DescriptionTest()
 {
     Player target = new Player(); // TODO: Initialize to an appropriate value
     string expected = string.Empty; // TODO: Initialize to an appropriate value
     string actual;
     target.Description = expected;
     actual = target.Description;
     Assert.AreEqual(expected, actual);
 }
        public ActionResult Create(Player player)
        {
            if (ModelState.IsValid)
            {
                db.Players.Add(player);
                db.SaveChanges();
                return RedirectToAction("Index");
            }

            return View(player);
        }
 public ActionResult Edit(Player player)
 {
     if (ModelState.IsValid)
     {
         db.Entry(player).State = EntityState.Modified;
         db.SaveChanges();
         return RedirectToAction("Index");
     }
     return View(player);
 }
示例#4
0
 public void IDTest()
 {
     Player target = new Player(); // TODO: Initialize to an appropriate value
     int expected = 0; // TODO: Initialize to an appropriate value
     int actual;
     target.ID = expected;
     actual = target.ID;
     Assert.AreEqual(expected, actual);
 }
示例#5
0
 public void SchedulesTest()
 {
     Player target = new Player(); // TODO: Initialize to an appropriate value
     ICollection<PlayerSchedule> expected = null; // TODO: Initialize to an appropriate value
     ICollection<PlayerSchedule> actual;
     target.Schedules = expected;
     actual = target.Schedules;
     Assert.AreEqual(expected, actual);
 }