- Python 3.6.9
- Django 3.2.4
- Django Rest Framework 3.12.4
- Clone the repository
- Go to the root folder and create the environment:
python3 -m venv env
- Then, activate it:
source env/bin/activate
- Install dependencies with
pip3
:pip3 install -r requirements.txt
- Run migrations (if there's not database):
python3 manage.py migrate
- Go to the root folder and run the server:
python3 manage.py runserver
- Tests using Coverage
coverage run --source='.' manage.py test blog
coverage report --omit=*/env/*,*/app/*,manage.py
python3 manage.py seed_post [post_quantity]
: this command create mock objects for table post, also post_quantity is a required argument, integer and must be greater than 0
- At the
postman
folder, there's Postman Collection to test the API