gnunet-svn
[Top][All Lists]
Advanced

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

[taler-anastasis] branch master updated: preparing test users, sandbox s


From: gnunet
Subject: [taler-anastasis] branch master updated: preparing test users, sandbox side
Date: Sun, 22 Aug 2021 11:35:41 +0200

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

ms pushed a commit to branch master
in repository anastasis.

The following commit(s) were added to refs/heads/master by this push:
     new b44c62c  preparing test users, sandbox side
b44c62c is described below

commit b44c62c82078733e74b3299122cec3209492de98
Author: MS <ms@taler.net>
AuthorDate: Sat Aug 21 22:35:33 2021 -1100

    preparing test users, sandbox side
---
 src/cli/test_iban.sh | 52 ++++++++++++++++++++++++++++++++++++++++++----------
 1 file changed, 42 insertions(+), 10 deletions(-)

diff --git a/src/cli/test_iban.sh b/src/cli/test_iban.sh
index 4da6a32..95adbd8 100755
--- a/src/cli/test_iban.sh
+++ b/src/cli/test_iban.sh
@@ -27,6 +27,34 @@ function cleanup()
 # Install cleanup handler (except for kill -9)
 trap cleanup EXIT
 
+# $1=ebics username, $2=ebics partner name, $3=person name, $4=sandbox bank 
account name, $5=iban
+function prepare_sandbox_account() {
+
+  echo Activating ebics subscriber $1 at the sandbox
+  libeufin-cli \
+    sandbox --sandbox-url=$SANDBOX_URL \
+      ebicssubscriber create \
+        --host-id=ebicstesthost \
+        --partner-id=$2 \
+        --user-id=$1
+  
+  echo "Giving a bank account ($4) to $1"
+  libeufin-cli \
+    sandbox --sandbox-url=$SANDBOX_URL \
+      ebicsbankaccount create \
+        --iban=$5 \
+        --bic="BCMAESM1XXX"\
+        --person-name=$3 \
+        --account-name=$4 \
+        --ebics-user-id=$1 \
+        --ebics-host-id=ebicstesthost \
+        --ebics-partner-id=$2 \
+        --currency=$CURRENCY
+
+
+
+}
+
 # Script's guidelines:
 
 #* uses 'CURRENCY=TESTKUDOS' and uses $CURRENCY for all
@@ -77,7 +105,6 @@ if ! psql -d anastasischeck -c "\q" &> /dev/null; then
   exit_skip "Postgresql database 'anastasischeck' not reachable"
 fi
 
-CURRENCY="TESTKUDOS"
 export LIBEUFIN_NEXUS_DB_CONNECTION="jdbc:sqlite:$(mktemp -u 
/tmp/nexus-db-XXXXXX.sqlite)"
 export LIBEUFIN_SANDBOX_DB_CONNECTION="jdbc:sqlite:$(mktemp -u 
/tmp/sandbox-db-XXXXXX.sqlite)"
 NEXUS_URL="http://localhost:5001/";
@@ -99,12 +126,17 @@ if ! curl -s --retry 5 --retry-connrefused $SANDBOX_URL > 
/dev/null; then
 fi
 echo "Sandbox started."
 
-#libeufin-nexus serve &> nexus.log &
-#nexus_pid=$!
-#echo "Starting Sandbox .."
-#libeufin-sandbox serve &> sandbox.log &
-#sandbox_pid=$!
-#
-#
-#curl -s --retry 5 --retry-connrefused $NEXUS_URL > /dev/null
-#curl -s --retry 5 --retry-connrefused $SANDBOX_URL > /dev/null
+CURRENCY="TESTKUDOS"
+IBAN1="AA3314655813489414469157"
+IBAN2="BB3314655813489414469157"
+
+echo Making a ebics host at the sandbox
+libeufin-cli \
+  sandbox --sandbox-url=$SANDBOX_URL \
+    ebicshost create \
+      --host-id=ebicstesthost
+
+prepare_sandbox_account \
+  ebicsuser01 ebicspartner01 Person01 sandbox-account-01 $IBAN1
+prepare_sandbox_account \
+  ebicsuser02 ebicspartner02 Person02 sandbox-account-02 $IBAN2

-- 
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]