diff options
Diffstat (limited to 'packages/taler-harness/src')
-rw-r--r-- | packages/taler-harness/src/integrationtests/test-timetravel-withdraw.ts | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/packages/taler-harness/src/integrationtests/test-timetravel-withdraw.ts b/packages/taler-harness/src/integrationtests/test-timetravel-withdraw.ts index e594d2d72..9cd0beb42 100644 --- a/packages/taler-harness/src/integrationtests/test-timetravel-withdraw.ts +++ b/packages/taler-harness/src/integrationtests/test-timetravel-withdraw.ts @@ -21,6 +21,7 @@ import { Duration, TransactionMajorState, TransactionType, + j2s, } from "@gnu-taler/taler-util"; import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; import { GlobalTestState } from "../harness/harness.js"; @@ -69,7 +70,7 @@ export async function runTimetravelWithdrawTest(t: GlobalTestState) { console.log("starting withdrawal via bank"); // This should fail, as the wallet didn't time travel yet. - await withdrawViaBankV2(t, { + const wres2 = await withdrawViaBankV2(t, { walletClient, bank, exchange, @@ -82,9 +83,11 @@ export async function runTimetravelWithdrawTest(t: GlobalTestState) { { const transactions = await walletClient.call( WalletApiOperation.GetTransactions, - {}, + { + sort: "stable-ascending", + }, ); - console.log(transactions); + console.log(j2s(transactions)); const types = transactions.transactions.map((x) => x.type); t.assertDeepEqual(types, ["withdrawal", "withdrawal"]); const wtrans = transactions.transactions[1]; @@ -98,9 +101,9 @@ export async function runTimetravelWithdrawTest(t: GlobalTestState) { offsetMs: Duration.toMilliseconds(timetravelDuration), }); - // This doesn't work yet, see https://bugs.taler.net/n/6585 + // The wallet should do denomination re-selection and succeed - // await wallet.runUntilDone({ maxRetries: 5 }); + await wres2.withdrawalFinishedCond; } runTimetravelWithdrawTest.suites = ["wallet"]; |