public void GetCarsWithLowerPrice()
        {
            var data = new List <Car>
            {
                new Car {
                    Model = "Car1", Price = 5500M
                },
                new Car {
                    Model = "Car2", Price = 5300M
                },
                new Car {
                    Model = "Car3", Price = 5000M
                },
            }.AsQueryable();

            var mockSet = new Mock <DbSet <Car> >();

            mockSet.As <IQueryable <Car> >().Setup(m => m.Provider).Returns(data.Provider);
            mockSet.As <IQueryable <Car> >().Setup(m => m.Expression).Returns(data.Expression);
            mockSet.As <IQueryable <Car> >().Setup(m => m.ElementType).Returns(data.ElementType);
            mockSet.As <IQueryable <Car> >().Setup(m => m.GetEnumerator()).Returns(data.GetEnumerator());

            var mockContext = new Mock <CarDealershipContext>();

            mockContext.Setup(m => m.Cars).Returns(mockSet.Object);

            var service   = new CarBusiness(mockContext.Object);
            var CarsFound = service.GetCarsWithLowerPrice(5400M);

            Assert.AreEqual(2, CarsFound.Count());
            Assert.AreEqual("Car2", CarsFound[0].Model);
            Assert.AreEqual("Car3", CarsFound[1].Model);
        }
        /// <summary>
        /// Populate the data grid with information about cars with price lower than given
        /// </summary>
        private void PopulateDataGridViewGetCarsWithLowerPrice()
        {
            dataGridView.Rows.Clear(); HideSpecificInfo();
            CarBusiness carBusiness = new CarBusiness();

            int.TryParse(txtGet.Text, out int price);
            var carsList = carBusiness.GetCarsWithLowerPrice(price);

            DataPopulator(carsList);
        }