aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-cli
diff options
context:
space:
mode:
Diffstat (limited to 'packages/taler-wallet-cli')
-rw-r--r--packages/taler-wallet-cli/src/integrationtests/libeufin.ts2
-rw-r--r--packages/taler-wallet-cli/src/integrationtests/test-libeufin-api-facade.ts2
-rw-r--r--packages/taler-wallet-cli/src/integrationtests/test-libeufin-facade-anastasis.ts31
-rw-r--r--packages/taler-wallet-cli/src/integrationtests/testrunner.ts2
4 files changed, 18 insertions, 19 deletions
diff --git a/packages/taler-wallet-cli/src/integrationtests/libeufin.ts b/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
index f9266a39d..c5580be9d 100644
--- a/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/libeufin.ts
@@ -1165,7 +1165,7 @@ export namespace LibeufinNexusApi {
username: string = "admin",
password: string = "test",
): Promise<any> {
- let url = new URL("/history/incoming", anastasisBaseUrl);
+ let url = new URL("history/incoming", anastasisBaseUrl);
let response = await axios.get(url.href, { params: params,
auth: {
username: username,
diff --git a/packages/taler-wallet-cli/src/integrationtests/test-libeufin-api-facade.ts b/packages/taler-wallet-cli/src/integrationtests/test-libeufin-api-facade.ts
index 0a0957b37..b0e569146 100644
--- a/packages/taler-wallet-cli/src/integrationtests/test-libeufin-api-facade.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/test-libeufin-api-facade.ts
@@ -53,7 +53,7 @@ export async function runLibeufinApiFacadeTest(t: GlobalTestState) {
// check that original facade shows up.
t.assertTrue(resp.data["facades"][0]["name"] == user01nexus.twgReq["name"]);
- const twgBaseUrl: string = resp.data["facades"][0]["twgBaseUrl"];
+ const twgBaseUrl: string = resp.data["facades"][0]["baseUrl"];
t.assertTrue(typeof twgBaseUrl === "string");
t.assertTrue(twgBaseUrl.startsWith("http://"));
t.assertTrue(twgBaseUrl.endsWith("/"));
diff --git a/packages/taler-wallet-cli/src/integrationtests/test-libeufin-facade-anastasis.ts b/packages/taler-wallet-cli/src/integrationtests/test-libeufin-facade-anastasis.ts
index 528d398ac..0bcc9a0bc 100644
--- a/packages/taler-wallet-cli/src/integrationtests/test-libeufin-facade-anastasis.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/test-libeufin-facade-anastasis.ts
@@ -29,7 +29,7 @@ import {
/**
* Run basic test with LibEuFin.
*/
-export async function runLibeufinApiFacadeTest(t: GlobalTestState) {
+export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) {
/**
* User saltetd "01"
*/
@@ -52,37 +52,34 @@ export async function runLibeufinApiFacadeTest(t: GlobalTestState) {
libeufinServices.libeufinNexus,
);
// check that original facade shows up.
- t.assertTrue(resp.data["facades"][0]["name"] == user01nexus.twgReq["name"]);
-
- const anastasisBaseUrl: string = resp.data["facades"][0]["twgBaseUrl"];
+ t.assertTrue(resp.data["facades"][0]["name"] == user01nexus.anastasisReq["name"]);
+ const anastasisBaseUrl: string = resp.data["facades"][0]["baseUrl"];
t.assertTrue(typeof anastasisBaseUrl === "string");
t.assertTrue(anastasisBaseUrl.startsWith("http://"));
t.assertTrue(anastasisBaseUrl.endsWith("/"));
LibeufinSandboxApi.simulateIncomingTransaction(
libeufinServices.libeufinSandbox,
- user01nexus.localAccountName,
+ user01sandbox.ebicsBankAccount.label,
{
debtorIban: "ES3314655813489414469157",
debtorBic: "BCMAESM1XXX",
debtorName: "Mock Donor",
subject: "Anastasis donation",
- amount: "EUR:3",
+ amount: "3", // Sandbox takes currency from its "config"
},
)
- //***************************************//
- // Here payments need to be generated //
- // and checked via the Anastasis facade. //
- //***************************************//
-
- // delete it.
- resp = await LibeufinNexusApi.deleteFacade(
+ await LibeufinNexusApi.fetchAllTransactions(
libeufinServices.libeufinNexus,
- user01nexus.anastasisReq["name"],
+ user01nexus.localAccountName,
);
- // check that no facades show up.
- t.assertTrue(!resp.data.hasOwnProperty("facades"));
+
+ let txs = await LibeufinNexusApi.getAnastasisTransactions(
+ libeufinServices.libeufinNexus,
+ anastasisBaseUrl, {delta: 5})
+
+ // FIXME: test more!
}
-runLibeufinApiFacadeTest.suites = ["libeufin"];
+runLibeufinAnastasisFacadeTest.suites = ["libeufin"];
diff --git a/packages/taler-wallet-cli/src/integrationtests/testrunner.ts b/packages/taler-wallet-cli/src/integrationtests/testrunner.ts
index 6f68706af..cb1d621b6 100644
--- a/packages/taler-wallet-cli/src/integrationtests/testrunner.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/testrunner.ts
@@ -63,6 +63,7 @@ import { runLibeufinTutorialTest } from "./test-libeufin-tutorial";
import { runLibeufinApiPermissionsTest } from "./test-libeufin-api-permissions";
import { runLibeufinApiFacadeTest } from "./test-libeufin-api-facade";
import { runLibeufinApiFacadeBadRequestTest } from "./test-libeufin-api-facade-bad-request";
+import { runLibeufinAnastasisFacadeTest } from "./test-libeufin-facade-anastasis";
import { runLibeufinApiSchedulingTest } from "./test-libeufin-api-scheduling";
import { runLibeufinApiBankconnectionTest } from "./test-libeufin-api-bankconnection";
import { runLibeufinApiUsersTest } from "./test-libeufin-api-users";
@@ -106,6 +107,7 @@ const allTests: TestMainFunction[] = [
runLibeufinApiPermissionsTest,
runLibeufinApiFacadeTest,
runLibeufinApiFacadeBadRequestTest,
+ runLibeufinAnastasisFacadeTest,
runLibeufinApiSchedulingTest,
runLibeufinApiUsersTest,
runLibeufinApiBankaccountTest,