Exemple #1
0
        public ActionResult Clear()
        {
            Place.ClearAll();
            List <Place> allPlaces = Place.GetInstances();

            return(View("../Home/Index", allPlaces));
        }
        public ActionResult Clear()
        {
            Place.ClearAll();
            List <Place> allPlaces = Place.GetAll();

            return(View("Index", allPlaces));
        }
        public void DeleteAll_EmptyTheListOfPlaces_EmptyList()
        {
            Place newPlace = new Place("Timbuktu", "Great Food!");

            newPlace.Save();
            Place.ClearAll();
            List <Place> expectedResults  = new List <Place> {
            };
            List <Place> databaseContents = Place.GetAll();

            CollectionAssert.AreEqual(expectedResults, databaseContents);
        }
Exemple #4
0
 public ActionResult Delete()
 {
     Place.ClearAll();
     return(View());
 }
Exemple #5
0
 public ActionResult DeleteAll()
 {
     Place.ClearAll();
     return(View("Index"));
 }
Exemple #6
0
 public void Dispose()
 {
     Place.ClearAll();
 }
 public void Dispose()
 {
     // Teardown - reset data after every test
     Place.ClearAll();
 }
Exemple #8
0
 public ActionResult DeleteAll()
 {
     Place.ClearAll();
     return(RedirectToAction("Index"));
 }
Exemple #9
0
 public ActionResult ListClear()
 {
     Place.ClearAll();
     return(View());
 }
 public ActionResult DeleteAll()
 {
     //Clears all places
     Place.ClearAll();
     return(View());
 }