aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2023-10-16 13:19:10 +0200
committerFlorian Dold <florian@dold.me>2023-10-16 13:19:10 +0200
commit925a97c2e3a52222cb28b2b64d80c0b01305defe (patch)
treeb0d6ec9e63f4020be59ca2c286166efecfa08ac1 /packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts
parent9504687813d3ee47131f5b7f66c1426f9ccffd41 (diff)
downloadwallet-core-925a97c2e3a52222cb28b2b64d80c0b01305defe.tar.xz
-fix tests
Diffstat (limited to 'packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts')
-rw-r--r--packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts15
1 files changed, 9 insertions, 6 deletions
diff --git a/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts b/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts
index 449142809..def2462e0 100644
--- a/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts
+++ b/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts
@@ -136,20 +136,22 @@ export async function runTimetravelAutorefreshTest(t: GlobalTestState) {
},
);
- await walletClient.call(WalletApiOperation.TestingWaitTransactionsFinal, {});
-
let p: PendingOperationsResponse;
p = await walletClient.call(WalletApiOperation.GetPendingOperations, {});
console.log("pending operations after first time travel");
console.log(JSON.stringify(p, undefined, 2));
- await withdrawViaBankV2(t, {
+ await walletClient.call(WalletApiOperation.TestingWaitTasksProcessed, {});
+ await walletClient.call(WalletApiOperation.TestingWaitTransactionsFinal, {});
+
+ const wres2 = await withdrawViaBankV2(t, {
walletClient,
bank,
exchange,
amount: "TESTKUDOS:20",
});
+ await wres2.withdrawalFinishedCond;
await walletClient.call(WalletApiOperation.TestingWaitTransactionsFinal, {});
@@ -165,12 +167,13 @@ export async function runTimetravelAutorefreshTest(t: GlobalTestState) {
},
);
+ await walletClient.call(WalletApiOperation.TestingWaitTasksProcessed, {});
+ await walletClient.call(WalletApiOperation.TestingWaitTransactionsFinal, {});
+
// At this point, the original coins should've been refreshed.
// It would be too late to refresh them now, as we're past
// the two year deposit expiration.
- await walletClient.call(WalletApiOperation.TestingWaitTransactionsFinal, {});
-
const orderResp = await merchantClient.createOrder({
order: {
fulfillment_url: "http://example.com",
@@ -195,7 +198,7 @@ export async function runTimetravelAutorefreshTest(t: GlobalTestState) {
t.assertTrue(r.status === PreparePayResultType.PaymentPossible);
const cpr = await walletClient.call(WalletApiOperation.ConfirmPay, {
- proposalId: r.proposalId,
+ transactionId: r.transactionId,
});
t.assertTrue(cpr.type === ConfirmPayResultType.Done);