diff options
author | Florian Dold <florian@dold.me> | 2023-08-24 18:29:54 +0200 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2023-08-24 18:30:03 +0200 |
commit | 6cc3fb3d0466e89b67be271009a2fc95f3ed41ca (patch) | |
tree | fc21999997bcdbed6c66dc2970dfc473a85bfd37 /packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts | |
parent | f5596767e1ad8f6461a6e64d61519783928624d2 (diff) | |
download | wallet-core-6cc3fb3d0466e89b67be271009a2fc95f3ed41ca.tar.xz |
harness: modernize some tests
Diffstat (limited to 'packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts')
-rw-r--r-- | packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts b/packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts index 396f0f03f..61687ec02 100644 --- a/packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts +++ b/packages/taler-harness/src/integrationtests/test-withdrawal-bank-integrated.ts @@ -19,11 +19,7 @@ */ import { GlobalTestState } from "../harness/harness.js"; import { createSimpleTestkudosEnvironmentV2 } from "../harness/helpers.js"; -import { - WalletApiOperation, - BankApi, - BankAccessApi, -} from "@gnu-taler/taler-wallet-core"; +import { BankAccessApiClient, WalletApiOperation } from "@gnu-taler/taler-wallet-core"; import { j2s, NotificationType, @@ -44,10 +40,14 @@ export async function runWithdrawalBankIntegratedTest(t: GlobalTestState) { // Create a withdrawal operation - const user = await BankApi.createRandomBankUser(bank); - const wop = await BankAccessApi.createWithdrawalOperation( - bank, - user, + const bankAccessApiClient = new BankAccessApiClient({ + allowHttp: true, + baseUrl: bank.bankAccessApiBaseUrl, + }); + const user = await bankAccessApiClient.createRandomBankUser(); + bankAccessApiClient.setAuth(user); + const wop = await bankAccessApiClient.createWithdrawalOperation( + user.username, "TESTKUDOS:10", ); @@ -129,7 +129,7 @@ export async function runWithdrawalBankIntegratedTest(t: GlobalTestState) { // Confirm it - await BankApi.confirmWithdrawalOperation(bank, user, wop); + await bankAccessApiClient.confirmWithdrawalOperation(user.username, wop); await withdrawalBankConfirmedCond; |