This page list all the steps you need to follow to set up model_bakery
and be able to code it. Here they are:
- Fork this repo and clone it to your computer:
git clone git@github.com:YOUR_USER/model_bakery.git
- Install the dev dependencies:
pip install -r requirements_dev.txt
- Change the code and run your tests with:
make test
- We use pre-commit to ensure a unique code formatting for the project. But, if you ran into any CI issues with that, make sure your code changes respect it:
make lint
If you don't follow the step 4, your PR may fail due to black
, isort
, flake8
or pydocstyle
warnings.
To run postgresql
and postgis
specific tests:
-
Install the
postgis
dependencies. Follow the instructions from the Django docs:
If you are on Ubuntu/Debian you run the following:
sudo apt update -y && sudo apt install -y binutils libproj-dev gdal-bin
- Run the following script:
./postgis-tests.sh
That will spin up a docker
container with postgresql
and postgis
enabled and run the full test
suite.