Ejemplo n.º 1
0
        public void Find_FindsItemByIdField_CampingItem()
        {
            //Arrange
            string      item        = "chair";
            string      price       = "$3.00";
            string      weight      = "2 pounds";
            string      name        = "person";
            CampingItem campingItem = new CampingItem(item, price, weight, name);
            //Act
            CampingItem foundItem = CampingItem.Find(1);


            //Assert
            Assert.AreEqual(1, foundItem.Id);
        }
Ejemplo n.º 2
0
        public ActionResult Detail(int id)
        {
            CampingItem currentItem = CampingItem.Find(id);

            return(View(currentItem));
        }