public void UnParkVehicle_Test2() { var id = Guid.NewGuid().ToString(); var car = new Car(4, id); var parkingLot = new ParkingLot.ParkingLot(26); var result = parkingLot.ParkVehicle(car, DateTime.Today + new TimeSpan(8, 0, 0), DateTime.Today + new TimeSpan(10, 0, 0), 50); var result1 = parkingLot.UnParkVehicle(car); Assert.Equal(100.0, result1.parkingCost); }
public void ParkVehicle_CapacityTest_Test4() { var id = Guid.NewGuid().ToString(); var car = new Car(4, id); var bike = new Bike(2, Guid.NewGuid().ToString()); var parkingLot = new ParkingLot.ParkingLot(26); parkingLot.ParkVehicle(bike); var result = parkingLot.ParkVehicle(car, DateTime.Today + new TimeSpan(8, 0, 0), DateTime.Today + new TimeSpan(10, 0, 0), 50); parkingLot.UnParkVehicle(car); Assert.Equal(24, parkingLot.GetFreeParkingSpots()); }