diff --git a/docker/test/Dockerfile b/docker/test/Dockerfile index 0adfe689..9359f606 100644 --- a/docker/test/Dockerfile +++ b/docker/test/Dockerfile @@ -16,7 +16,8 @@ WORKDIR /app RUN git clone https://github.com/googleapis/googleapis.git COPY proto ./proto -COPY install-rpc.sh itests/test.sh itests/test.py squeakserver/common/lnd_lightning_client.py ./ +COPY install-rpc.sh itests/test.sh squeakserver/common/lnd_lightning_client.py ./ +COPY itests/tests ./tests # Install the gRPC files. RUN chmod +x install-rpc.sh && \ diff --git a/itests/test.sh b/itests/test.sh index 27759385..ea9ae9d9 100644 --- a/itests/test.sh +++ b/itests/test.sh @@ -1,3 +1,3 @@ #!/bin/bash -python3 test.py +pytest -s tests diff --git a/itests/tests/__init__.py b/itests/tests/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/itests/test.py b/itests/tests/test_buy.py similarity index 99% rename from itests/test.py rename to itests/tests/test_buy.py index e788cced..5c69b665 100644 --- a/itests/test.py +++ b/itests/tests/test_buy.py @@ -92,7 +92,7 @@ def string_to_hex(s): return bytes.fromhex(s) -def run(): +def test_buy_squeak(): # Set the network to simnet for itest. SelectParams("mainnet") @@ -471,6 +471,6 @@ def run(): ) -if __name__ == "__main__": - logging.basicConfig() - run() +# if __name__ == "__main__": +# logging.basicConfig() +# run() diff --git a/requirements-itest.txt b/requirements-itest.txt index 24c1aef2..20122639 100644 --- a/requirements-itest.txt +++ b/requirements-itest.txt @@ -4,3 +4,4 @@ argparse googleapis-common-protos grpcio grpcio-tools +pytest