Add client, models and tests
Introduces SetraClient. The client is made for use against the SETRA(SEntralt TRAnsaksjonslager) API. There are models for Batch, Voucher, Transaction and Multi, where Multi is a combination of the preceding, The Multi model validates that the batchid of the voucher matches the batch included, and that the voucherid of the transactions matches one of the included vouchers. Tests have also been included for the client itself, the endpoints, and the models. Configuration for tox, Jenkins and gitlab-ci are included for running tests and building the client.
Showing
- .gitignore 8 additions, 0 deletions.gitignore
- .gitlab-ci.yml 26 additions, 0 deletions.gitlab-ci.yml
- Jenkinsfile 29 additions, 0 deletionsJenkinsfile
- README.md 51 additions, 1 deletionREADME.md
- example-config.json 33 additions, 0 deletionsexample-config.json
- requirements-test.txt 3 additions, 0 deletionsrequirements-test.txt
- requirements.txt 3 additions, 0 deletionsrequirements.txt
- setra_client/__init__.py 6 additions, 0 deletionssetra_client/__init__.py
- setra_client/client.py 217 additions, 0 deletionssetra_client/client.py
- setra_client/models.py 79 additions, 0 deletionssetra_client/models.py
- setra_client/version.py 18 additions, 0 deletionssetra_client/version.py
- setup.py 95 additions, 0 deletionssetup.py
- tests/__init__.py 0 additions, 0 deletionstests/__init__.py
- tests/conftest.py 61 additions, 0 deletionstests/conftest.py
- tests/fixtures/batch_fixture.json 8 additions, 0 deletionstests/fixtures/batch_fixture.json
- tests/fixtures/multi_fail_fixture.json 68 additions, 0 deletionstests/fixtures/multi_fail_fixture.json
- tests/fixtures/multi_fixture.json 68 additions, 0 deletionstests/fixtures/multi_fixture.json
- tests/fixtures/trans_fail_fixture.json 23 additions, 0 deletionstests/fixtures/trans_fail_fixture.json
- tests/fixtures/trans_fixture.json 24 additions, 0 deletionstests/fixtures/trans_fixture.json
- tests/fixtures/voucher_fixture.json 6 additions, 0 deletionstests/fixtures/voucher_fixture.json
Loading
Please register or sign in to comment