gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-anastasis] branch master updated: Taler 0.9.0 migrations for cli


From: gnunet
Subject: [taler-anastasis] branch master updated: Taler 0.9.0 migrations for cli tests
Date: Tue, 17 Jan 2023 21:57:11 +0100

This is an automated email from the git hooks/post-receive script.

grothoff pushed a commit to branch master
in repository anastasis.

The following commit(s) were added to refs/heads/master by this push:
     new 4ae2d09  Taler 0.9.0 migrations for cli tests
4ae2d09 is described below

commit 4ae2d095b860ab4f476b2ed7df8123a5618bacd6
Author: Christian Grothoff <christian@grothoff.org>
AuthorDate: Tue Jan 17 21:57:07 2023 +0100

    Taler 0.9.0 migrations for cli tests
---
 ...tasis_reducer_recovery_enter_user_attributes.sh | 39 +++++++++++++++++-----
 1 file changed, 31 insertions(+), 8 deletions(-)

diff --git a/src/cli/test_anastasis_reducer_recovery_enter_user_attributes.sh 
b/src/cli/test_anastasis_reducer_recovery_enter_user_attributes.sh
index 49814cd..b32dd5d 100755
--- a/src/cli/test_anastasis_reducer_recovery_enter_user_attributes.sh
+++ b/src/cli/test_anastasis_reducer_recovery_enter_user_attributes.sh
@@ -15,6 +15,27 @@ function exit_fail() {
     exit 1
 }
 
+# Stop libeufin sandbox and nexus (if running)
+function stop_libeufin()
+{
+    echo "Stopping libeufin..."
+    if test -f libeufin-sandbox.pid
+    then
+        PID=`cat libeufin-sandbox.pid 2> /dev/null`
+        echo "Killing libeufin sandbox $PID"
+        rm libeufin-sandbox.pid
+        kill $PID 2> /dev/null || true
+    fi
+    if test -f libeufin-nexus.pid
+    then
+        PID=`cat libeufin-nexus.pid 2> /dev/null`
+        echo "Killing libeufin nexus $PID"
+        rm libeufin-nexus.pid
+        kill $PID 2> /dev/null || true
+    fi
+    echo "Stopping libeufin DONE"
+}
+
 # Cleanup to run whenever we exit
 function cleanup()
 {
@@ -22,6 +43,7 @@ function cleanup()
     do
         kill $n 2> /dev/null || true
     done
+    stop_libeufin
     rm -rf $CONF $WALLET_DB $R1FILE $R2FILE $B1FILE $B2FILE $TMP_DIR
     wait
 }
@@ -91,8 +113,8 @@ taler-exchange-httpd -h > /dev/null || exit_skip " 
taler-exchange required"
 taler-merchant-httpd -h > /dev/null || exit_skip " taler-merchant required"
 echo " FOUND"
 
-echo -n "Testing for taler-bank-manage"
-taler-bank-manage --help >/dev/null </dev/null || exit_skip " MISSING"
+echo -n "Testing for taler-bank-manage-testing"
+taler-bank-manage-testing --help >/dev/null </dev/null || exit_skip " MISSING"
 echo " FOUND"
 echo -n "Testing for taler-wallet-cli"
 taler-wallet-cli -v >/dev/null </dev/null || exit_skip " MISSING"
@@ -140,8 +162,8 @@ MASTER_PUB=`gnunet-ecc -p $MASTER_PRIV_FILE`
 EXCHANGE_URL=`taler-config -c $CONF -s EXCHANGE -o BASE_URL`
 MERCHANT_PORT=`taler-config -c $CONF -s MERCHANT -o PORT`
 MERCHANT_URL=http://localhost:${MERCHANT_PORT}/
-BANK_PORT=`taler-config -c $CONF -s BANK -o HTTP_PORT`
-BANK_URL=http://localhost:${BANK_PORT}/
+NEXUS_PORT=8082
+BANK_URL=http://localhost:1${NEXUS_PORT}/
 AUDITOR_URL=http://localhost:8083/
 AUDITOR_PRIV_FILE=`taler-config -f -c $CONF -s AUDITOR -o AUDITOR_PRIV_FILE`
 AUDITOR_PRIV_DIR=`dirname $AUDITOR_PRIV_FILE`
@@ -176,7 +198,8 @@ echo " OK"
 
 # Launch services
 echo -n "Launching taler services ..."
-taler-bank-manage-testing $CONF postgres:///$TALER_DB serve > taler-bank.log 
2> taler-bank.err &
+rm -f $TALER_DB
+taler-bank-manage-testing $NEXUS_PORT $TALER_DB $EXCHANGE_URL $CONF > 
taler-bank.log 2> taler-bank.err &
 taler-exchange-secmod-eddsa -c $CONF 2> taler-exchange-secmod-eddsa.log &
 taler-exchange-secmod-rsa -c $CONF 2> taler-exchange-secmod-rsa.log &
 taler-exchange-secmod-cs -c $CONF 2> taler-exchange-secmod-cs.log &
@@ -238,9 +261,9 @@ echo -n "Setting up keys ..."
 taler-exchange-offline -c $CONF \
   download \
   sign \
-  enable-account payto://x-taler-bank/localhost/Exchange \
+  enable-account `taler-config -c $CONF -s exchange-account-1 -o PAYTO_URI` \
   enable-auditor $AUDITOR_PUB $AUDITOR_URL "TESTKUDOS Auditor" \
-  wire-fee now x-taler-bank TESTKUDOS:0.01 TESTKUDOS:0.01 TESTKUDOS:0.01 \
+  wire-fee now iban TESTKUDOS:0.01 TESTKUDOS:0.01 \
   upload &> taler-exchange-offline.log
 
 echo -n "."
@@ -295,7 +318,7 @@ echo "OK"
 echo -n "Configuring merchant instance ..."
 # Setup merchant
 
-curl -H "Content-Type: application/json" -X POST -d 
'{"auth":{"method":"external"},"payto_uris":["payto://x-taler-bank/localhost/43"],"id":"default","name":"default","address":{},"jurisdiction":{},"default_max_wire_fee":"TESTKUDOS:1",
 
"default_max_deposit_fee":"TESTKUDOS:1","default_wire_fee_amortization":1,"default_wire_transfer_delay":{"d_ms"
 : 3600000},"default_pay_delay":{"d_ms": 3600000}}' 
http://localhost:9966/management/instances
+curl -H "Content-Type: application/json" -X POST -d 
'{"auth":{"method":"external"},"payto_uris":["payto://x-taler-bank/localhost/43"],"id":"default","name":"default","address":{},"jurisdiction":{},"default_max_wire_fee":"TESTKUDOS:1",
 
"default_max_deposit_fee":"TESTKUDOS:1","default_wire_fee_amortization":1,"default_wire_transfer_delay":{"d_us"
 : 3600000000},"default_pay_delay":{"d_us": 3600000000}}' 
http://localhost:9966/management/instances
 
 
 echo " DONE"

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]