diff options
author | Christian Grothoff <christian@grothoff.org> | 2023-08-23 10:29:29 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2023-08-23 10:29:29 +0200 |
commit | 8cc927b778a8476deda5ffcdf1e91607f9667db8 (patch) | |
tree | c41910833b2bbf40f97b1f2d74fe86f16d9b9088 | |
parent | fc461d11a86bd33ca70259b85a4aa7d6875e12c9 (diff) | |
download | exchange-8cc927b778a8476deda5ffcdf1e91607f9667db8.tar.xz |
setup accounts also for fakebank setup
-rwxr-xr-x | src/testing/taler-unified-setup.sh | 35 |
1 files changed, 33 insertions, 2 deletions
diff --git a/src/testing/taler-unified-setup.sh b/src/testing/taler-unified-setup.sh index 04a80c653..bdd7bf192 100755 --- a/src/testing/taler-unified-setup.sh +++ b/src/testing/taler-unified-setup.sh @@ -227,6 +227,20 @@ register_sandbox_account() { unset LIBEUFIN_SANDBOX_PASSWORD } +register_fakebank_account() { + BODY='{"username":"'"$1"'","password":"'"$2"'"}' + wget \ + --post-data="$BODY" \ + --header='Content-type: application/json' \ + --tries=3 \ + --waitretry=1 \ + --timeout=30 \ + "http://localhost:$BANK_PORT/taler-bank-access/testing/register" \ + -o /dev/null \ + -O /dev/null \ + >/dev/null +} + if [[ "1" = "$START_NEXUS" || "1" = "$START_FAKEBANK" ]] then @@ -449,10 +463,13 @@ fi if [ "1" = "$START_FAKEBANK" ] then echo "Setting up fakebank ..." - $USE_VALGRIND taler-fakebank-run -c "$CONF" -L "$LOGLEVEL" -n 4 2> taler-fakebank-run.log & + $USE_VALGRIND taler-fakebank-run\ + -c "$CONF" \ + -L "$LOGLEVEL" \ + -n 4 \ + 2> taler-fakebank-run.log & fi - if [ "1" = "$START_EXCHANGE" ] then echo -n "Starting exchange ..." @@ -598,6 +615,20 @@ then echo " OK" fi +if [ "1" = "$START_FAKEBANK" ] +then + echo -n "Register Fakebank users ..." + register_fakebank_account fortytwo x + register_fakebank_account fortythree x + register_fakebank_account exchange x + register_fakebank_account tor x + register_fakebank_account gnunet x + register_fakebank_account tutorial x + register_fakebank_account survey x + echo " DONE" +fi + + echo -n "Waiting for Taler services ..." # Wait for all other taler services to be available E_DONE=0 |