Virtual environment setup
python3 -m venv .venv
source ./.venv/bin/activateInstalling django through pip
pip install django
pip install django-debug-toolbarcd tutorialBefore running the project, making the necessary migrations is required:
python3 manage.py makemigrations polls
python3 manage.py migrateNow we are able to run the server
python3 manage.py runserverpython3 manage.py shellpython3 manage.py test pollsUsing coverage
# Installation on the virtual environment
pip install coverage# Running tests and gathering coverage data
coverage run --source='.' manage.py test polls
# Showing results
coverage reportThe admin override template files must be placed in tutorial/templates/admin/ folder. In order to override the default admin templates, you must first find the original in this repo, copy and paste it to the previous mentioned folder and do the modifications.
This project follows the official django tutorial