taler-typescript-core

Wallet core logic and WebUIs for various components
Log | Files | Refs | Submodules | README | LICENSE

commit f487064c98bfd523b317432ad64e2b9d5999056e
parent 6ebb07dbb128e48aeb79b0370d6f172cce6cdd1c
Author: Florian Dold <florian@dold.me>
Date:   Mon, 11 Nov 2024 13:52:42 +0100

fix asserts / add logging in kyc-skip-expiration

Diffstat:
Mpackages/taler-harness/src/integrationtests/test-kyc-skip-expiration.ts | 16+++++++++++++---
1 file changed, 13 insertions(+), 3 deletions(-)

diff --git a/packages/taler-harness/src/integrationtests/test-kyc-skip-expiration.ts b/packages/taler-harness/src/integrationtests/test-kyc-skip-expiration.ts @@ -63,7 +63,6 @@ export const AML_PROGRAM_FROM_ATTRIBUTES_TO_CONTEXT: TalerKycAml.AmlProgramDefin custom_measures: { ask_more_info: { context: { - info: _input?.attributes, // this is the context info that the KYC-SPA will see WAT: "REALLY?", }, @@ -255,6 +254,9 @@ export async function runKycSkipExpirationTest(t: GlobalTestState) { t.assertDeepEqual(decisionsResp.status, 200); } + // Make sure that there can be another decision + await waitMs(2000); + // Wait for the KYC program to run while (true) { const infoResp = await harnessHttpLib.fetch( @@ -266,6 +268,16 @@ export async function runKycSkipExpirationTest(t: GlobalTestState) { await waitMs(1000); continue; } + // KYC program still busy. + // In the future, this should long-poll. + if (infoResp.status == 204) { + await waitMs(1000); + continue; + } + + const respJson = await infoResp.json(); + console.log(j2s(respJson)); + t.assertDeepEqual(infoResp.status, 200); const clientInfo = await readResponseJsonOrThrow( @@ -277,8 +289,6 @@ export async function runKycSkipExpirationTest(t: GlobalTestState) { // Finally here we must see the officer defined form t.assertDeepEqual(clientInfo?.requirements[0].context, { - // info contains the properties in the aml decision - info: { form: { name: "string" } }, // this is fixed by the aml program WAT: "REALLY?", });