Project to generate random data about cars in colombia.
- VehicleID (Primary Key): Unique identifier for each vehicle.
- LicensePlate: The license plate number of the vehicle.
- Brand: The brand or manufacturer of the vehicle.
- Model: The model of the vehicle.
- Year: The manufacturing year of the vehicle.
- Color: The color of the vehicle.
- FuelType: The type of fuel the vehicle uses (e.g., gasoline, diesel, electric).
- TransmissionType: The type of transmission (e.g., automatic, manual).
- OdometerReading: The current odometer reading of the vehicle.
- RegistrationDate: The date when the vehicle was registered.
- InsuranceProvider: The insurance provider for the vehicle.
- InsuranceExpirationDate: The expiration date of the vehicle insurance.
- OwnerName: The name of the vehicle owner.
- OwnerID: Identification number of the vehicle owner.
- OwnerAddress: The address of the vehicle owner.
- City: The city where the vehicle is registered.
- Department: The department (administrative region) where the vehicle is registered.
- VehicleType: The type of vehicle (e.g., sedan, SUV, truck).
- EngineSize: The size of the vehicle engine.
- WheelDrive: The type of wheel drive (e.g., 2WD, 4WD).
- LastMaintenanceDate: The date of the vehicle's last maintenance.
- NumberOfSeats: The number of seats in the vehicle.
- NumberOfDoors: The number of doors in the vehicle.
- GPSInstalled: Indicates whether the vehicle has a GPS system installed.
- EmissionStandard: The emission standard the vehicle complies with.
- SafetyRating: Safety rating of the vehicle.
- InsuranceCoverageType: Type of coverage in the vehicle insurance.
- EstimatedMarketValue: Estimated market value
- VehicleStatus: IN_USE,SELLING,MAINTENANCE
- AccidentHistory:
Taken from ChatGPT
- Car Color https://www.elcarrocolombiano.com/industria/colores-de-autos-mas-populares-2021/
- Brand https://www.eltiempo.com/economia/finanzas-personales/estas-son-las-marcas-de-carros-mas-vendidas-en-colombia-en-2023-801990
- fuel_type https://www.semana.com/economia/actualidad/vida-ejecutiva/automoviles/articulo/en-colombia-de-los-vehiculos-a-gas-natural-el-77-por-ciento-son-buses-y-el-16-camiones/202218/
- transmission_type https://noticias.autocosmos.com.co/2020/04/21/los-autos-con-caja-mecanica-tienden-a-desaparecer
- insurance_provider https://aliarseguros.com/blog-mejores-aseguradoras-autos-colombia
- city https://noticias.autocosmos.com.co/2019/10/03/en-que-lugares-de-colombia-se-matriculan-mas-vehiculos
- vehicle_type https://www.motor.com.co/industria/En-2023-se-vendieron-186.222-vehiculos-nuevos-en-Colombia.-Cayo--29-el-mercado.-20240102-0006.html
Python 3.11.0
virtualenv env
source env/bin/activate
pip3 install -r requirements.txt
python -m unittest
Make sure you have "coverage" in your requirements.txt file and run pip install.
Then run coverage run -m unittest discover
and after that run coverage report
to get the following table:
Name Stmts Miss Cover
----------------------------------------------------------
base/__init__.py 0 0 100%
base/test/__init__.py 0 0 100%
generators/__init__.py 0 0 100%
generators/random_generator.py 43 3 93%
generators/test/__init__.py 0 0 100%
generators/test/test_algorithm.py 29 1 97%
random_resolvers/__init__.py 0 0 100%
random_resolvers/general_resolver.py 77 2 97%
utils/__init__.py 0 0 100%
utils/constants.py 2 0 100%
utils/file_manager.py 12 2 83%
utils/random_util.py 18 0 100%
----------------------------------------------------------
TOTAL 181 8 96%
This code has been beautify using black: https://github.com/psf/black.
The command to use is black . -l 120
.