Simple REST application providing access to data about cars, and system for rating them.
- You have to have installed docker and docker-compose on your computer.
- Rename .env-default file to .env.
- Type command
docker-compose up --build
in terminal in project root directory. - Open browser with url
http://0.0.0.0:8000
orhttp://127.0.0.1:8000
on Windows. - Enjoy!
https://capirs.herokuapp.com/cars/
GET and POST cars.- https://capirs.herokuapp.com/cars/ DELETE a car.
- https://capirs.herokuapp.com/popular/ GET information about cars popularity.
- https://capirs.herokuapp.com/rate/ POST raring for the car.
You can check documentation for API here.
- Start application.
- To run tests, type command
docker-compose exec backend coverage run manage.py test
in terminal in project root directory. - To run coverage, type command
docker-compose exec backend python manage.py test
in terminal in project root directory. - To view coverage report in command line, type command
docker-compose exec backend coverage report
in terminal in project root directory.
Module | statements | missing | excluded | coverage |
---|---|---|---|---|
Total | 77 | 0 | 0 | 100% |
cars/models.py | 16 | 0 | 0 | 100% |
cars/serializers.py | 39 | 0 | 0 | 100% |
cars/urls.py | 4 | 0 | 0 | 100% |
cars/views.py | 18 | 0 | 0 | 100% |
* ----------------------------------------------------------------------------
* "THE BEER-WARE LICENSE" (Revision 42):
* <phk@FreeBSD.ORG> wrote this file. As long as you retain this notice you
* can do whatever you want with this stuff. If we meet some day, and you think
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------