Skip to content

millerf/v6_api

 
 

Repository files navigation

GitHub license Build Status Total alerts Language grade: Python Codacy Badge Known Vulnerabilities

Development environment

On any OS, install git and docker. Then :

Install

# Download camptocamp.org source code :
git clone https://github.com/c2corg/v6_api
cd v6_api

Run

# the very first call may be quite long, (15 minutes, depending of your bandwith)
# time to make a coffee
docker-compose up

❤️ http://localhost:6543 ❤️

Press CTRL+C to terminate it.

Run the background jobs and syncer scripts

In distinct terminals:

docker-compose exec api make -f config/docker-dev run-background-jobs
docker-compose exec api make -f config/docker-dev run-syncer

Check code quality

In another terminal (docker-compose up must be running) :

./scripts/lint.sh

Run test suite

In another terminal (docker-compose up must be running) :

# full tests, take a while
./scripts/test.sh

# If you need to test a specific point: 
./scripts/test.sh c2corg_api/tests/models/test_book.py

# or:
./scripts/test.sh c2corg_api/tests/models/test_book.py::TestBook

# or even:
./scripts/test.sh c2corg_api/tests/models/test_book.py::TestBook::test_to_archive

Useful links in wiki

Full info about development environment

Packages

No packages published

Languages

  • Python 98.0%
  • Scala 1.2%
  • Shell 0.3%
  • Makefile 0.2%
  • PLpgSQL 0.2%
  • Dockerfile 0.1%