public void TestCleanup()
 {
     //remove test data
     if (testVehicleId != 0)
     {
         _vehicleManager.DeleteVehicle(testVehicleId);
     }
 }
Example #2
0
 public IActionResult DeleteVehicle(int vehicleNumber)
 {
     if (manager.DeleteVehicle(vehicleNumber) != null)
     {
         return(Ok($"Vehicle number {vehicleNumber} deleted"));
     }
     return(NotFound());
 }
Example #3
0
        public IActionResult DeleteVehicle(int vehicleId)
        {
            var v = _vehicleManager.DeleteVehicle(vehicleId);

            if (v == null)
            {
                return(NotFound());
            }
            return(Ok(v));
        }