implement based on hexagonal architecture
mamba + expects + mocks tests for the service
Reference:
https://medium.com/@vsavkin/hexagonal-architecture-for-rails-developers-8b1fee64a613 https://en.wikipedia.org/wiki/Hexagonal_architecture_(software) https://www.youtube.com/watch?v=tg5RFeSfBM4
- Go to the project folder
cd path/to/flask-test-project- Create virtualenv.
python3 -m venv env- Activate it.
source env/bin/activate- Install requirement packages:
pip install -r requirements.txt- Create db:
(venv) $ python3
>>> from app import db
>>> db.create_all()Run app:
python3 app.pyRun tests example command:
pipenv run mamba tests/test_route_create.py