Author: Navule Pavan Kumar Rao
python3 -m pip install --upgrade pip
python3 -m venv env
source env/bin/activate
python3 -m pip install --upgrade pip
pip install -r requirements.txt
pyinstaller parking_lot.py
copy the contents of the generate dist/parking_lot directory to the gojek provided bin directory and read the instructions mentioned in How to run.md
python parking_lot.py file_inputs.txt
python parking_lot.py
exit
python3 -m unittest
pyinstaller parking_lot.py
Run coverage run parking_lot.py file_inputs.txt
Run coverage run parking_lot.py
and play with edge cases
coverage report -m
Name Stmts Miss Cover Missing
-------------------------------------------------------
input_processor.py 90 19 79% 29-32, 35-43, 53, 62, 92, 98, 123, 127-128
models/__init__.py 0 0 100%
models/car.py 8 0 100%
models/slot.py 16 0 100%
parking_lot.py 14 2 86% 15-17
service/__init__.py 0 0 100%
service/lot_handler.py 64 4 94% 25, 47-49
service/park_service.py 60 17 72% 16, 23, 26, 51, 59, 66, 71-75, 83, 91, 95, 100-103
util/__init__.py 0 0 100%
util/constants.py 14 0 100%
-------------------------------------------------------
TOTAL 266 42 84%
coverage html -d coverage_html
Html report located in coverage_html\index.html
directory