gnunet-svn
[Top][All Lists]
Advanced

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

[taler-wallet-core] 01/03: Pass Sandbox credentials to the CLI's env.


From: gnunet
Subject: [taler-wallet-core] 01/03: Pass Sandbox credentials to the CLI's env.
Date: Fri, 15 Oct 2021 07:50:29 +0200

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

ms pushed a commit to branch master
in repository wallet-core.

commit c25b26983c45520ccc239b6532d54393a08aeabf
Author: ms <ms@taler.net>
AuthorDate: Thu Oct 14 20:26:02 2021 +0200

    Pass Sandbox credentials to the CLI's env.
---
 .../src/integrationtests/libeufin.ts               | 36 ++++++++++------------
 1 file changed, 17 insertions(+), 19 deletions(-)

diff --git a/packages/taler-wallet-cli/src/integrationtests/libeufin.ts 
b/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
index a5f37a6b..61be10c7 100644
--- a/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
@@ -218,17 +218,6 @@ export class LibeufinSandboxService implements 
LibeufinSandboxServiceInterface {
         LIBEUFIN_SANDBOX_DB_CONNECTION: this.sandboxConfig.databaseJdbcUri,
       },
     );
-    await runCommand(
-      this.globalTestState,
-      "libeufin-sandbox-superuser",
-      "libeufin-sandbox",
-      ["superuser", "admin", "--password", "test"],
-      {
-        ...process.env,
-        LIBEUFIN_SANDBOX_DB_CONNECTION: this.sandboxConfig.databaseJdbcUri,
-      },
-    );
-
     this.sandboxProc = this.globalTestState.spawnService(
       "libeufin-sandbox",
       ["serve", "--port", `${this.sandboxConfig.httpPort}`],
@@ -236,6 +225,7 @@ export class LibeufinSandboxService implements 
LibeufinSandboxServiceInterface {
       {
         ...process.env,
         LIBEUFIN_SANDBOX_DB_CONNECTION: this.sandboxConfig.databaseJdbcUri,
+        LIBEUFIN_SANDBOX_ADMIN_PASSWORD: "secret",
       },
     );
   }
@@ -271,7 +261,7 @@ export class LibeufinSandboxService implements 
LibeufinSandboxServiceInterface {
   }
 
   async pingUntilAvailable(): Promise<void> {
-    const url = `${this.baseUrl}config`;
+    const url = this.baseUrl;
     await pingProc(this.sandboxProc, url, "libeufin-sandbox");
   }
 }
@@ -485,14 +475,22 @@ export class LibeufinCli {
     this.cliDetails = cd;
   }
 
+  env(): any {
+    return {
+      ...process.env,
+      LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl,
+      LIBEUFIN_SANDBOX_USERNAME: "admin",
+      LIBEUFIN_SANDBOX_PASSWORD: "secret",
+    }
+  }
+
   async checkSandbox(): Promise<void> {
     const stdout = await sh(
       this.globalTestState,
       "libeufin-cli-checksandbox",
       "libeufin-cli sandbox check",
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
-    console.log(stdout);
   }
 
   async createEbicsHost(hostId: string): Promise<void> {
@@ -500,7 +498,7 @@ export class LibeufinCli {
       this.globalTestState,
       "libeufin-cli-createebicshost",
       `libeufin-cli sandbox ebicshost create --host-id=${hostId}`,
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
     console.log(stdout);
   }
@@ -515,7 +513,7 @@ export class LibeufinCli {
         ` --host-id=${details.hostId}` +
         ` --partner-id=${details.partnerId}` +
         ` --user-id=${details.userId}`,
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
     console.log(stdout);
   }
@@ -536,7 +534,7 @@ export class LibeufinCli {
         ` --ebics-host-id=${sd.hostId}` +
         ` --ebics-partner-id=${sd.partnerId}` +
         ` --ebics-user-id=${sd.userId}`,
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
     console.log(stdout);
   }
@@ -546,7 +544,7 @@ export class LibeufinCli {
       this.globalTestState,
       "libeufin-cli-generatetransactions",
       `libeufin-cli sandbox bankaccount generate-transactions ${accountName}`,
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
     console.log(stdout);
   }
@@ -556,7 +554,7 @@ export class LibeufinCli {
       this.globalTestState,
       "libeufin-cli-showsandboxtransactions",
       `libeufin-cli sandbox bankaccount transactions ${accountName}`,
-      { ...process.env, LIBEUFIN_SANDBOX_URL: this.cliDetails.sandboxUrl },
+      this.env()
     );
     console.log(stdout);
   }

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