This is a simple fastapi mongodb template which some common features.
To use poetry as package manager head over to poetry branch
- JWT Authentication
- Logging
- RBAC
- Testing with pytest
- Coverage
This template uses uv for package management. First install uv then follow below steps
Install the dependencies by
uv sync
Then you can source the virtual environment by
source .venv/bin/activate
Run the backend server by
make run
or
make dev
Testing is done using pytest
make test
or
make test-vv
Coverage package is used to measure code coverage.
This will test the code coverage and covert that report to html format in folder named htmlcov.
You have to open the index.html directly from the folder.
`make coverage`