This repository provides a template for building applications using the Clean Architecture principles with Python.
- Python
- FastAPI
- SQLAlchemy
- Docker
- pytest
- coverage
git clone https://github.com/javiertelioz/clean-architecture-python.gitNavigate to the project directory:
cd clean-architecture-pythonStart the application using Docker Compose:
docker-compose up -dOnce the application is running, you can access the API documentation at http://localhost:8000.
Lint the code using the following command:
docker-compose run --rm web autopep8 --in-place --aggressive --recursive .Run the tests using the following command:
docker-compose run --rm web pytestTo generate a test coverage report, run the following commands:
docker-compose run --rm web coverage run -m pytest
docker-compose run --rm web coverage report -mThe coverage report will show the percentage of code coverage for the project.
Feel free to customize the code and directory structure to suit your specific needs. Happy coding!