Tests are written and executed using Pytest.
- Enter nix shell in the project root folder to open a shell which is your test environment:
cd ekklesia-portal nix-shell
- Compile translations:
ipython makebabel.ipy compile
- Create a config file named
testconfig.ymlusing the config template from
tests/testconfig.example.ymlMake sure that the database connection string points to an empty + writable database.
- Initialize the test database:
python tests/create_test_db.py -c testconfig.yml
- The tests can be run with
pytestfrom the repository root directory.