libeufin

Integration and sandbox testing for FinTech APIs and data formats
Log | Files | Refs | Submodules | README | LICENSE

commit 1910639c259816dbdafac7f923abadd61d655a7c
parent ea502185c7e76f49724e970350bb40588f7037b3
Author: MS <ms@taler.net>
Date:   Fri, 13 Nov 2020 22:38:11 +0100

Integration tests.

Testing a empty transaction history
before any payment is made or received.

Diffstat:
Mintegration-tests/tests.py | 16++++++++++------
Mintegration-tests/util.py | 1+
2 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/integration-tests/tests.py b/integration-tests/tests.py @@ -126,10 +126,14 @@ startSandbox(SANDBOX_DB) prepareSandbox() prepareNexus() -#def test_0(): -# assertResponse( -# REQUEST HERE! -# ) +def test_empty_history(): + resp = assertResponse( + get( + f"http://localhost:5001/bank-accounts/{NEXUS_BANK_LABEL}/transactions", + auth=NEXUS_AUTH + ) + ) + assert len(resp.json().get("transactions")) == 0 -flushTablesNexus(NEXUS_DB) -flushTablesSandbox(SANDBOX_DB) +# flushTablesNexus(NEXUS_DB) +# flushTablesSandbox(SANDBOX_DB) diff --git a/integration-tests/util.py b/integration-tests/util.py @@ -156,3 +156,4 @@ def startNexus(dbname="nexus-test.sqlite3"): def assertResponse(response, acceptedResponses=[200]): assert response.status_code in acceptedResponses + return response