From 73d1458fbd1ba2b117cb3eea171f21f13a8b6677 Mon Sep 17 00:00:00 2001 From: woodser <13068859+woodser@users.noreply.github.com> Date: Fri, 20 Jun 2025 08:45:07 -0400 Subject: [PATCH] test amazon e-gift card payment account over grpc api --- src/HavenoClient.test.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/HavenoClient.test.ts b/src/HavenoClient.test.ts index 981069c9..e4603b6f 100644 --- a/src/HavenoClient.test.ts +++ b/src/HavenoClient.test.ts @@ -4749,6 +4749,11 @@ function testPaymentAccount(account: PaymentAccount, form: PaymentAccountForm) { expect(account.getTradeCurrenciesList().length).toEqual(1); expect(account.getTradeCurrenciesList()[0].getCode()).toEqual("USD"); break; + case PaymentAccountForm.FormId.AMAZON_GIFT_CARD: + expect(account.getPaymentAccountPayload()!.getAmazonGiftCardAccountPayload()!.getEmailOrMobileNr()!).toEqual(getFormField(form, PaymentAccountFormField.FieldId.EMAIL_OR_MOBILE_NR).getValue()); + expect(account.getPaymentAccountPayload()!.getAmazonGiftCardAccountPayload()!.getCountryCode()!).toEqual(getFormField(form, PaymentAccountFormField.FieldId.COUNTRY).getValue()); + expect(account.getTradeCurrenciesList().map(currency => currency.getCode()).join(",")).toEqual(getFormField(form, PaymentAccountFormField.FieldId.TRADE_CURRENCIES).getValue()); + break; default: throw new Error("Unhandled payment method type: " + form.getId()); }