public void AuthorizedUserCannotAddRoomIfHeIsNotAdminnistrator() { var user = new User("user12", "user12", Roles.User); var data = new HotelBookingSystemData(); var controller = new RoomsController(data, user); var view = controller.Add(1, 2, 30.00m); }
public void UnAuthorizedUserCannotViewBookings() { var data = new HotelBookingSystemData(); var controller = new RoomsController(data, null); var view = controller.ViewBookings(1); }
public void AuthorizedUserCannotAddPeriodIfHeIsNotAdminnistrator() { var user = new User("user12", "user12", Roles.User); var data = new HotelBookingSystemData(); var controller = new RoomsController(data, user); var view = controller.AddPeriod(1, DateTime.Now, DateTime.Now); }
public void UnAuthorizedUserCannotAddPeriod() { var data = new HotelBookingSystemData(); var controller = new RoomsController(data, null); var view = controller.AddPeriod(1, DateTime.Now, DateTime.Now); }
public void UnAuthorizedUserCannotAddRoom() { var data = new HotelBookingSystemData(); var controller = new RoomsController(data, null); var view = controller.Add(1, 2, 30.00m); }
public void UnAuthorizedUserCannotBook() { var data = new HotelBookingSystemData(); var controller = new RoomsController(data, null); var view = controller.Book(1, DateTime.Now, DateTime.Now, "comment one"); }