In order to run the app, follow the next steps:
- Add input data in data/operations.json file
- Run the app
python -m app.app
Run with docker:
- Build the image
docker build -t rides .
- And then run the container image
docker run rides
General logic that read rides data and validate the input type.
Driver functions for ban or activate a driver.
Rides functions to start or finish a ride.
Folder to store input data.
Folder that contains the schema validations for the input data. For example validate the input for a new driver.
All app test cases. In order to run the test cases run the following command:
py.test
Note: Install dependencies first. Follow the next steps:
- Make a virtual env:
python3 -m venv ../venv
- Activate the env:
source ../venv/bin/activate
- Install the package:
pip install -r requirements.txt
- Run the test!