diff options
Diffstat (limited to 'packages/taler-wallet-embedded/src/wallet-qjs.ts')
-rw-r--r-- | packages/taler-wallet-embedded/src/wallet-qjs.ts | 33 |
1 files changed, 28 insertions, 5 deletions
diff --git a/packages/taler-wallet-embedded/src/wallet-qjs.ts b/packages/taler-wallet-embedded/src/wallet-qjs.ts index 2eaac0b0b..0296dfeb6 100644 --- a/packages/taler-wallet-embedded/src/wallet-qjs.ts +++ b/packages/taler-wallet-embedded/src/wallet-qjs.ts @@ -34,22 +34,22 @@ import { CoreApiMessageEnvelope, CoreApiResponse, CoreApiResponseSuccess, + Logger, + WalletNotification, enableNativeLogging, getErrorDetailFromException, j2s, - Logger, setGlobalLogLevelFromString, - WalletNotification, } from "@gnu-taler/taler-util"; import { createPlatformHttpLib } from "@gnu-taler/taler-util/http"; import { qjsOs } from "@gnu-taler/taler-util/qtart"; import { - createNativeWalletHost2, DefaultNodeWalletArgs, - openPromise, - performanceNow, Wallet, WalletApiOperation, + createNativeWalletHost2, + openPromise, + performanceNow, } from "@gnu-taler/taler-wallet-core"; setGlobalLogLevelFromString("trace"); @@ -283,6 +283,27 @@ export async function testWithGv() { }); } +export async function testWithFdold() { + const w = await createNativeWalletHost2({ + config: { + features: { + allowHttp: true, + }, + }, + }); + await w.wallet.client.call(WalletApiOperation.InitWallet, {}); + await w.wallet.client.call(WalletApiOperation.RunIntegrationTest, { + amountToSpend: "TESTKUDOS:1" as AmountString, + amountToWithdraw: "TESTKUDOS:3" as AmountString, + corebankApiBaseUrl: "https://bank.taler.fdold.eu/", + exchangeBaseUrl: "https://exchange.taler.fdold.eu/", + merchantBaseUrl: "https://merchant.taler.fdold.eu/", + }); + await w.wallet.runTaskLoop({ + stopWhenDone: true, + }); +} + export async function testWithLocal(path: string) { console.log("running local test"); const w = await createNativeWalletHost2({ @@ -347,3 +368,5 @@ globalThis.testArgon2id = testArgon2id; globalThis.testReduceAction = reduceAction; // @ts-ignore globalThis.testDiscoverPolicies = discoverPolicies; +// @ts-ignore +globalThis.testWithFdold = testWithFdold; |