The meal tracking app of Andela Lagos
This repository houses the API endpoints for the waitress project. This project makes use of Python3.5 and above. For production it makes use of Python 3.7.6
It can be found here
Before you start please ensure you have Python and PostgreSQL installed
-
Install Python3 from here or run the command
brew install python3
-
Install Pipenv with the command
pip install pipenv
-
Create a vritual environment with the command
pipenv shell
- Install postgresql (Mac OS X)
Copy the following into your ~/.bash_profile
or ~/.zshrc
if you use zsh and you think your postgres isn't properly configured
export PATH=$PATH:/Applications/Postgres.app/Contents/Versions/latest/bin
- Clone the repository
git clone [email protected]:waitress-andela/waitress.git
- Pip install all requirements for the app
Before installing dependencies make sure your virtual env is activated, if not run pipenv shell
to activate
pipenv install
-
Create a copy of the
.env.example
file and rename to.env
. -
Add the different variables as they are needed to get the project running.
-
Migrate the models to your database
pipenv run python manage.py makemigrations
pipenv run python manage.py migrate
- Startup the server
pipenv run python manage.py runserver
- Navigate to the api doc built with swagger
And you are all setup :)
To test the application and see the coverage
- Run coverage
coverage run manage.py test
to know how much of the app is covered by automated testing. - View the report of the coverage on your terminal
coverage report
. - Produce the html of coverage result
coverage html
.