diff options
author | Florian Dold <florian@dold.me> | 2020-11-03 15:56:02 +0100 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2020-11-03 15:56:02 +0100 |
commit | ca343e4e0037cd986b3115079d370e61fc5897ce (patch) | |
tree | ae5ebf8fa6fdc8704272eb94151dd3f086413ec9 /packages/taler-integrationtests/src/test-paywall-flow.ts | |
parent | e259d109efd998d0ff6197123a47b83bfe274680 (diff) | |
download | wallet-core-ca343e4e0037cd986b3115079d370e61fc5897ce.tar.xz |
fix broken integration tests due to merchant API changes
Diffstat (limited to 'packages/taler-integrationtests/src/test-paywall-flow.ts')
-rw-r--r-- | packages/taler-integrationtests/src/test-paywall-flow.ts | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/packages/taler-integrationtests/src/test-paywall-flow.ts b/packages/taler-integrationtests/src/test-paywall-flow.ts index 350a60dde..54c8ab463 100644 --- a/packages/taler-integrationtests/src/test-paywall-flow.ts +++ b/packages/taler-integrationtests/src/test-paywall-flow.ts @@ -69,6 +69,8 @@ runTest(async (t: GlobalTestState) => { t.assertTrue(orderStatus.order_status === "unpaid"); + const talerPayUriOne = orderStatus.taler_pay_uri; + t.assertTrue(orderStatus.already_paid_order_id === undefined); let publicOrderStatusUrl = orderStatus.order_status_url; @@ -140,16 +142,14 @@ runTest(async (t: GlobalTestState) => { sessionId: "mysession-two", }); - // Should be unpaid because of a new session ID - t.assertTrue(orderStatus.order_status === "unpaid"); - - publicOrderStatusUrl = orderStatus.order_status_url; + // Should be claimed (not paid!) because of a new session ID + t.assertTrue(orderStatus.order_status === "claimed"); // Pay with new taler://pay URI, which should // have the new session ID! // Wallet should now automatically re-play payment. preparePayResp = await wallet.preparePay({ - talerPayUri: orderStatus.taler_pay_uri, + talerPayUri: talerPayUriOne, }); t.assertTrue(preparePayResp.status === PreparePayResultType.AlreadyConfirmed); @@ -208,7 +208,7 @@ runTest(async (t: GlobalTestState) => { sessionId: "mysession-four", }); - t.assertTrue(orderStatus.order_status === "unpaid"); + t.assertTrue(orderStatus.order_status === "claimed"); // Now check if the public status of the new order is correct. |