public void GenerateDronesPack() { var rand = new Random(); for (int i = 0; i < 5; i++) { var drone = new Drone() { Code = Guid.NewGuid().ToString(), MaxAvailableWeigth = rand.NextDouble() * 3, MaxSpeed = rand.NextDouble() * 20 + 12, Type = (DroneType)rand.Next(0, 3), Weigth = rand.NextDouble() * 2 + 0.3 }; _droneRepository.Add(drone); } }