added script for ci testing

Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com>
This commit is contained in:
Lorenz Herzberger 2022-02-17 08:48:59 +01:00
parent cdb465d6bc
commit f2a87a2c9c
No known key found for this signature in database
GPG Key ID: FA5EE906EB55316A
2 changed files with 13 additions and 0 deletions

View File

@ -15,6 +15,7 @@ elif [[ ${PLANETMINT_ACCEPTANCE_TEST} == 'enable' ]]; then
./run-acceptance-test.sh
elif [[ ${PLANETMINT_INTEGRATION_TEST} == 'enable' ]]; then
./run-integration-test.sh
./scripts/test.sh
else
docker-compose exec planetmint pytest -v --cov=planetmint --cov-report xml:htmlcov/coverage.xml
fi

12
scripts/test.sh Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
# Copyright © 2020 Interplanetary Database Association e.V.,
# Planetmint and IPDB software contributors.
# SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
# Code is Apache-2.0 and docs are CC-BY-4.0
result=$(ssh root@64.225.106.52 'bash -s' < ./election.sh elect 35)
ssh root@64.225.105.60 'bash -s' < ./election.sh approve $result
exitcode=$?
exit exitcode