public void Arrange() { _repo = new OutingsRepo(); _outings = new Outings("JulyGolf", OutingType.Golf, 30, DateTime.Parse("7/13/2020"), 100.00); _repo.AddOuting(_outings); }
public void GetOutingList_ShouldWork() { OutingsRepo testRepo = new OutingsRepo(); List <OutingsClass> _listOfOutings = testRepo.GetOutingList(); Console.WriteLine(_listOfOutings); }
public void CreateNewOuting_ShouldGetCorrectBool() { //Arrange Outings newOuting = new Outings(); OutingsRepo repo = new OutingsRepo(); //Act bool createOuting = repo.CreateNewOuting(newOuting); //Assert Assert.IsTrue(createOuting); }
public void ViewAllOutings_ShouldReturnCorrectBool() { //Arrange Outings newOuting = new Outings(); OutingsRepo repo = new OutingsRepo(); repo.CreateNewOuting(newOuting); //Act List <Outings> contents = repo.ViewAllOutings(); bool directoryHasContent = contents.Contains(newOuting); //Assert Assert.IsTrue(directoryHasContent); }
public void AddToList_ShouldBeNotNull() { //Arange Outings outing = new Outings(); outing.OutingName = "JulyGolf"; OutingsRepo repo = new OutingsRepo(); //Act repo.AddOuting(outing); Outings itemFromDir = repo.GetOutingByName("JulyGolf"); //Assert Assert.IsNotNull(itemFromDir); }
public void AddOutingToList_ShouldWork() { // Arrange OutingsRepo testRepo = new OutingsRepo(); OutingsClass newEvent = new OutingsClass { OutingType = "Sledding", NumPeopleAttended = 10, OutingDate = new DateTime(2020, 1, 10), TotalPersonCost = 25, TotalOutingCost = 350 }; List <OutingsClass> _listOfOutings = new List <OutingsClass>(); // Act _listOfOutings.Add(newEvent); // Assert Assert.IsTrue(_listOfOutings.Count > 0); }
public void Arrange() { eventList = new OutingsRepo(); }