Skip to content

Open source, composable payments platform | PCI compliant | SaaS and Self-host options | Enables connectivity to multiple payment, payout, fraud, vault and tokenization providers | Uplifts authorization with intelligent routing and revenue recovery | Reduce payment processing costs with cost observability | Reduces payment ops with reconciliation

feat(cypress): add last used tests (#7310)

Pa1NarKd70288aef5b3
diff --git a/cypress-tests-v2/cypress/fixtures/business_profile.json b/cypress-tests-v2/cypress/fixtures/business_profile.json
index 86410a03f6..d6ebd0c5cd 100644
--- a/cypress-tests-v2/cypress/fixtures/business_profile.json
+++ b/cypress-tests-v2/cypress/fixtures/business_profile.json
@@ -1,7 +1,7 @@
{
"bp_create": {
"profile_name": "HyperS",
- "return_url": "https://duck.com/success",
+ "return_url": "https://hyperswitch.io",
"enable_payment_response_hash": true,
"redirect_to_merchant_with_http_post": false,
"metadata": null,
@@ -31,7 +31,7 @@
},
"bp_update": {
"profile_name": "Hyperswitch",
- "return_url": "https://duck.com/success",
+ "return_url": "https://hyperswitch.io",
"enable_payment_response_hash": true,
"redirect_to_merchant_with_http_post": false,
"metadata": null,
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Adyen.js b/cypress-tests/cypress/e2e/configs/Payment/Adyen.js
index 493086314b..6f698cefa4 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Adyen.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Adyen.js
@@ -557,6 +557,31 @@ export const connectorDetails = {
},
},
},
+
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "succeeded",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/BankOfAmerica.js b/cypress-tests/cypress/e2e/configs/Payment/BankOfAmerica.js
index ef953956c5..98ea0f67c7 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/BankOfAmerica.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/BankOfAmerica.js
@@ -477,6 +477,24 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: getCustomExchange({
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ }),
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Commons.js b/cypress-tests/cypress/e2e/configs/Payment/Commons.js
index 963a0e50ab..691207c073 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Commons.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Commons.js
@@ -874,6 +874,23 @@ export const connectorDetails = {
},
},
}),
+ SaveCardUse3DSAutoCaptureOffSession: getCustomExchange({
+ Request: {
+ payment_method: "card",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ }),
SaveCardUseNo3DSManualCaptureOffSession: getCustomExchange({
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Cybersource.js b/cypress-tests/cypress/e2e/configs/Payment/Cybersource.js
index ae06e28332..7e36e6f40b 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Cybersource.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Cybersource.js
@@ -758,6 +758,35 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Configs: {
+ CONNECTOR_CREDENTIAL: {
+ value: "connector_1",
+ },
+ },
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "requires_customer_action",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Configs: {
CONNECTOR_CREDENTIAL: {
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Fiuu.js b/cypress-tests/cypress/e2e/configs/Payment/Fiuu.js
index 43834c7727..6dc05a9542 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Fiuu.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Fiuu.js
@@ -540,6 +540,43 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ billing: {
+ address: {
+ line1: "1467",
+ line2: "Harrison Street",
+ line3: "Harrison Street",
+ city: "San Fransico",
+ state: "California",
+ zip: "94122",
+ country: "NL",
+ first_name: "joseph",
+ last_name: "Doe",
+ },
+ email: "[email protected]",
+ },
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "succeeded",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Nexixpay.js b/cypress-tests/cypress/e2e/configs/Payment/Nexixpay.js
index b4b0bdb213..c0e8d1c573 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Nexixpay.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Nexixpay.js
@@ -551,6 +551,28 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Configs: {
+ TRIGGER_SKIP: true,
+ },
+ Request: {
+ payment_method: "card",
+ currency: "EUR",
+ billing: billingAddress,
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "requires_customer_action",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Configs: {
TRIGGER_SKIP: true,
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Noon.js b/cypress-tests/cypress/e2e/configs/Payment/Noon.js
index 61733a1aa3..c6aeead215 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Noon.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Noon.js
@@ -551,6 +551,24 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 200,
+ trigger_skip: true,
+ body: {
+ status: "requires_customer_action",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Novalnet.js b/cypress-tests/cypress/e2e/configs/Payment/Novalnet.js
index bafb45d034..a63c4ada81 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Novalnet.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Novalnet.js
@@ -280,6 +280,23 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "succeeded",
+ },
+ },
+ },
ZeroAuthPaymentIntent: {
Request: {
amount: 0,
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Paybox.js b/cypress-tests/cypress/e2e/configs/Payment/Paybox.js
index f70217059e..54dcb5cbeb 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Paybox.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Paybox.js
@@ -526,6 +526,23 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 400,
+ body: {
+ error: captureNotSupported,
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Paypal.js b/cypress-tests/cypress/e2e/configs/Payment/Paypal.js
index 982f082631..d2aed265d7 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Paypal.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Paypal.js
@@ -379,6 +379,23 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "succeeded",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/Stripe.js b/cypress-tests/cypress/e2e/configs/Payment/Stripe.js
index 9e557065f4..8b0e36c785 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/Stripe.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/Stripe.js
@@ -698,6 +698,36 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Configs: {
+ CONNECTOR_CREDENTIAL: {
+ specName: ["connectorAgnosticNTID"],
+ value: "connector_2",
+ },
+ },
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDSTestCardDetails,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: {
+ acceptance_type: "offline",
+ accepted_at: "1963-05-03T04:07:52.723Z",
+ online: {
+ ip_address: "127.0.0.1",
+ user_agent: "amet irure esse",
+ },
+ },
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "requires_customer_action",
+ },
+ },
+ },
SaveCardUseNo3DSManualCaptureOffSession: {
Request: {
payment_method: "card",
diff --git a/cypress-tests/cypress/e2e/configs/Payment/WorldPay.js b/cypress-tests/cypress/e2e/configs/Payment/WorldPay.js
index 7b78384768..88d2033d80 100644
--- a/cypress-tests/cypress/e2e/configs/Payment/WorldPay.js
+++ b/cypress-tests/cypress/e2e/configs/Payment/WorldPay.js
@@ -296,6 +296,23 @@ export const connectorDetails = {
},
},
},
+ SaveCardUse3DSAutoCaptureOffSession: {
+ Request: {
+ payment_method: "card",
+ payment_method_type: "debit",
+ payment_method_data: {
+ card: successfulThreeDsTestCardDetailsRequest,
+ },
+ setup_future_usage: "off_session",
+ customer_acceptance: customerAcceptance,
+ },
+ Response: {
+ status: 200,
+ body: {
+ status: "succeeded",
+ },
+ },
+ },
SaveCardConfirmAutoCaptureOffSession: {
Request: {
setup_future_usage: "off_session",
diff --git a/cypress-tests/cypress/e2e/spec/Payment/00023-PaymentMethods.cy.js b/cypress-tests/cypress/e2e/spec/Payment/00023-PaymentMethods.cy.js
index d88be29889..77018f9c70 100644
--- a/cypress-tests/cypress/e2e/spec/Payment/00023-PaymentMethods.cy.js
+++ b/cypress-tests/cypress/e2e/spec/Payment/00023-PaymentMethods.cy.js
@@ -3,6 +3,7 @@ import State from "../../../utils/State";
import getConnectorDetails, * as utils from "../../configs/Payment/Utils";
let globalState;
+let saveCardBody;
describe("Payment Methods Tests", () => {
before("seed global state", () => {
@@ -101,4 +102,174 @@ describe("Payment Methods Tests", () => {
cy.deletePaymentMethodTest(globalState);
});
});
+
+ context("'Last Used' off-session token payments", () => {
+ let shouldContinue = true;
+
+ beforeEach(function () {
+ saveCardBody = Cypress._.cloneDeep(fixtures.saveCardConfirmBody);
+ if (!shouldContinue) {
+ this.skip();
+ }
+ });
+ afterEach("flush global state", () => {
+ cy.task("setGlobalState", globalState.data);
+ });
+
+ it("Create customer", () => {
+ cy.createCustomerCallTest(fixtures.customerCreateBody, globalState);
+ });
+
+ context("Create No 3DS off session save card payment", () => {
+ it("create+confirm-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["SaveCardUseNo3DSAutoCaptureOffSession"];
+
+ cy.createConfirmPaymentTest(
+ fixtures.createConfirmPaymentBody,
+ data,
+ "no_three_ds",
+ "automatic",
+ globalState
+ );
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("List PM for customer", () => {
+ cy.listCustomerPMCallTest(globalState);
+ });
+ });
+
+ context("Create 3DS off session save card payment", () => {
+ it("create+confirm-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["SaveCardUse3DSAutoCaptureOffSession"];
+
+ cy.createConfirmPaymentTest(
+ fixtures.createConfirmPaymentBody,
+ data,
+ "three_ds",
+ "automatic",
+ globalState
+ );
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("Handle redirection", () => {
+ const expectedRedirection = fixtures.confirmBody["return_url"];
+ cy.handleRedirection(globalState, expectedRedirection);
+ });
+
+ it("List PM for customer", () => {
+ cy.listCustomerPMCallTest(globalState);
+ });
+ });
+
+ context("Create 3DS off session save card payment with token", () => {
+ beforeEach(function () {
+ saveCardBody = Cypress._.cloneDeep(fixtures.saveCardConfirmBody);
+ if (!shouldContinue) {
+ this.skip();
+ }
+ });
+
+ it("create-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["PaymentIntent"];
+
+ cy.createPaymentIntentTest(
+ fixtures.createPaymentBody,
+ data,
+ "three_ds",
+ "automatic",
+ globalState
+ );
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("confirm-save-card-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["SaveCardUseNo3DSAutoCapture"];
+
+ const newData = {
+ ...data,
+ Response: {
+ ...data.Response,
+ body: {
+ ...data.Response.body,
+ status: "requires_customer_action",
+ },
+ },
+ };
+
+ cy.saveCardConfirmCallTest(saveCardBody, newData, globalState);
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("Handle redirection", () => {
+ const expectedRedirection = fixtures.confirmBody["return_url"];
+ cy.handleRedirection(globalState, expectedRedirection);
+ });
+
+ it("List PM for customer", () => {
+ cy.listCustomerPMCallTest(globalState, 1 /* order */);
+ });
+ });
+
+ context("Create No 3DS off session save card payment with token", () => {
+ beforeEach(function () {
+ saveCardBody = Cypress._.cloneDeep(fixtures.saveCardConfirmBody);
+ if (!shouldContinue) {
+ this.skip();
+ }
+ });
+ afterEach("flush global state", () => {
+ cy.task("setGlobalState", globalState.data);
+ });
+
+ it("create-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["PaymentIntent"];
+
+ cy.createPaymentIntentTest(
+ fixtures.createPaymentBody,
+ data,
+ "no_three_ds",
+ "automatic",
+ globalState
+ );
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("confirm-save-card-payment-call-test", () => {
+ const data = getConnectorDetails(globalState.get("connectorId"))[
+ "card_pm"
+ ]["SaveCardUseNo3DSAutoCapture"];
+
+ cy.saveCardConfirmCallTest(saveCardBody, data, globalState);
+
+ if (shouldContinue)
+ shouldContinue = utils.should_continue_further(data);
+ });
+
+ it("List PM for customer", () => {
+ cy.listCustomerPMCallTest(globalState);
+ });
+ });
+ });
});
diff --git a/cypress-tests/cypress/fixtures/merchant-create-body.json b/cypress-tests/cypress/fixtures/merchant-create-body.json
index 08ed098742..d67ee7f421 100644
--- a/cypress-tests/cypress/fixtures/merchant-create-body.json
+++ b/cypress-tests/cypress/fixtures/merchant-create-body.json
@@ -21,7 +21,7 @@
"country": "US"
}
},
- "return_url": "https://duck.com/success",
+ "return_url": "https://hyperswitch.io",
"webhook_details": {
"webhook_version": "1.0.1",
"webhook_username": "ekart_retail",
diff --git a/cypress-tests/cypress/fixtures/merchant-update-body.json b/cypress-tests/cypress/fixtures/merchant-update-body.json
index 0fbf96d7d2..4d2ba6ef07 100644
--- a/cypress-tests/cypress/fixtures/merchant-update-body.json
+++ b/cypress-tests/cypress/fixtures/merchant-update-body.json
@@ -21,7 +21,7 @@
"country": "US"
}
},
- "return_url": "https://duck.com",
+ "return_url": "https://hyperswitch.io",
"webhook_details": {
"webhook_version": "1.0.1",
"webhook_username": "ekart_retail",
diff --git a/cypress-tests/cypress/support/commands.js b/cypress-tests/cypress/support/commands.js
index bf5ed37004..2ec260e9a6 100644
--- a/cypress-tests/cypress/support/commands.js
+++ b/cypress-tests/cypress/support/commands.js
@@ -2090,8 +2090,9 @@ Cypress.Commands.add(
saveCardConfirmBody.client_secret = globalState.get("clientSecret");
saveCardConfirmBody.payment_token = globalState.get("paymentToken");
saveCardConfirmBody.profile_id = profile_id;
- for (const key in reqData) {
- saveCardConfirmBody[key] = reqData[key];
+
+ if (reqData.billing === null) {
+ saveCardConfirmBody.billing = null;
}
cy.request({
@@ -2138,6 +2139,10 @@ Cypress.Commands.add(
expect(response.body)
.to.have.property("next_action")
.to.have.property("redirect_to_url");
+ globalState.set(
+ "nextActionUrl",
+ response.body.next_action.redirect_to_url
+ );
} else if (response.body.authentication_type === "no_three_ds") {
for (const key in resData.body) {
expect(resData.body[key]).to.equal(response.body[key]);
@@ -2156,6 +2161,10 @@ Cypress.Commands.add(
expect(response.body)
.to.have.property("next_action")
.to.have.property("redirect_to_url");
+ globalState.set(
+ "nextActionUrl",
+ response.body.next_action.redirect_to_url
+ );
} else if (response.body.authentication_type === "no_three_ds") {
for (const key in resData.body) {
expect(resData.body[key]).to.equal(response.body[key]);
@@ -2933,13 +2942,16 @@ Cypress.Commands.add("revokeMandateCallTest", (globalState) => {
Cypress.Commands.add(
"handleRedirection",
- (globalState, expected_redirection) => {
+ (globalState, expectedRedirection) => {
const connectorId = globalState.get("connectorId");
- const expected_url = new URL(expected_redirection);
- const redirection_url = new URL(globalState.get("nextActionUrl"));
+ const nextActionUrl = globalState.get("nextActionUrl");
+
+ const expectedUrl = new URL(expectedRedirection);
+ const redirectionUrl = new URL(nextActionUrl);
+
handleRedirection(
"three_ds",
- { redirection_url, expected_url },
+ { redirectionUrl, expectedUrl },
connectorId,
null
);
@@ -2948,19 +2960,21 @@ Cypress.Commands.add(
Cypress.Commands.add(
"handleBankRedirectRedirection",
- (globalState, payment_method_type, expected_redirection) => {
+ (globalState, paymentMethodType, expectedRedirection) => {
const connectorId = globalState.get("connectorId");
- const expected_url = new URL(expected_redirection);
- const redirection_url = new URL(globalState.get("nextActionUrl"));
+ const nextActionUrl = globalState.get("nextActionUrl");
+
+ const expectedUrl = new URL(expectedRedirection);
+ const redirectionUrl = new URL(nextActionUrl);
// explicitly restricting `sofort` payment method by adyen from running as it stops other tests from running
// trying to handle that specific case results in stripe 3ds tests to fail
- if (!(connectorId == "adyen" && payment_method_type == "sofort")) {
+ if (!(connectorId == "adyen" && paymentMethodType == "sofort")) {
handleRedirection(
"bank_redirect",
- { redirection_url, expected_url },
+ { redirectionUrl, expectedUrl },
connectorId,
- payment_method_type
+ paymentMethodType
);
}
}
@@ -2968,20 +2982,21 @@ Cypress.Commands.add(
Cypress.Commands.add(
"handleBankTransferRedirection",
- (globalState, payment_method_type, expected_redirection) => {
+ (globalState, paymentMethodType, expectedRedirection) => {
const connectorId = globalState.get("connectorId");
- const expected_url = new URL(expected_redirection);
- const redirection_url = new URL(globalState.get("nextActionUrl"));
- const next_action_type = globalState.get("nextActionType");
+ const nextActionUrl = globalState.get("nextActionUrl");
+ const nextActionType = globalState.get("nextActionType");
+
+ const expectedUrl = new URL(expectedRedirection);
+ const redirectionUrl = new URL(nextActionUrl);
- cy.log(payment_method_type);
handleRedirection(
"bank_transfer",
- { redirection_url, expected_url },
+ { redirectionUrl, expectedUrl },
connectorId,
- payment_method_type,
+ paymentMethodType,
{
- next_action_type,
+ nextActionType,
}
);
}
@@ -2989,66 +3004,104 @@ Cypress.Commands.add(
Cypress.Commands.add(
"handleUpiRedirection",
- (globalState, payment_method_type, expected_redirection) => {
+ (globalState, paymentMethodType, expected_redirection) => {
const connectorId = globalState.get("connectorId");
- const expected_url = new URL(expected_redirection);
- const redirection_url = new URL(globalState.get("nextActionUrl"));
+ const nextActionUrl = globalState.get("nextActionUrl");
+
+ const expectedUrl = new URL(expected_redirection);
+ const redirectionUrl = new URL(nextActionUrl);
handleRedirection(
"upi",
- { redirection_url, expected_url },
+ { redirectionUrl, expectedUrl },
connectorId,
- payment_method_type
+ paymentMethodType
);
}
);
-Cypress.Commands.add("listCustomerPMCallTest", (globalState) => {
+Cypress.Commands.add("listCustomerPMCallTest", (globalState, order = 0) => {
+ const apiKey = globalState.get("apiKey");
+ const baseUrl = globalState.get("baseUrl");
const customerId = globalState.get("customerId");
+ const url = `${baseUrl}/customers/${customerId}/payment_methods`;
+
cy.request({
method: "GET",
- url: `${globalState.get("baseUrl")}/customers/${customerId}/payment_methods`,
+ url: url,
headers: {
+ "api-key": apiKey,
"Content-Type": "application/json",
- "api-key": globalState.get("apiKey"),
},
}).then((response) => {
logRequestId(response.headers["x-request-id"]);
cy.wrap(response).then(() => {
expect(response.headers["content-type"]).to.include("application/json");
- if (response.body.customer_payment_methods[0]?.payment_token) {
+
+ // Validate response has payment methods
+ if (response.body.customer_payment_methods[order]?.payment_token) {
const paymentToken =
- response.body.customer_payment_methods[0].payment_token;
+ response.body.customer_payment_methods[order].payment_token;
const paymentMethodId =
- response.body.customer_payment_methods[0].payment_method_id;
- globalState.set("paymentToken", paymentToken); // Set paymentToken in globalState
- globalState.set("paymentMethodId", paymentMethodId); // Set paymentMethodId in globalState
+ response.body.customer_payment_methods[order].payment_method_id;
+ const lastUsedAt =
+ response.body.customer_payment_methods[order].last_used_at;
+
+ globalState.set("paymentMethodId", paymentMethodId);
+ globalState.set("paymentToken", paymentToken);
+
+ // Validate last_used_at timestamp
+ expect(new Date(lastUsedAt).getTime(), "last_used_at").to.be.lessThan(
+ Date.now()
+ ).and.to.not.be.null;
+
+ // For order > 0, validate payment methods are ordered by last_used_at
+ if (order > 0) {
+ const prevLastUsedAt =
+ response.body.customer_payment_methods[0].last_used_at;
+ expect(
+ new Date(prevLastUsedAt).getTime(),
+ "last_used_at ordering"
+ ).to.be.greaterThan(new Date(lastUsedAt).getTime());
+ }
} else {
- // We only get an empty array if something's wrong. One exception is a 4xx when no customer exist but it is handled in the test
expect(response.body)
.to.have.property("customer_payment_methods")
.to.be.an("array").and.empty;
}
- expect(globalState.get("customerId"), "customer_id").to.equal(
- response.body.customer_payment_methods[0].customer_id
- );
- expect(
- response.body.customer_payment_methods[0].payment_token,
- "payment_token"
- ).to.not.be.null;
- expect(
- response.body.customer_payment_methods[0].payment_method_id,
- "payment_method_id"
- ).to.not.be.null;
- expect(
- response.body.customer_payment_methods[0].payment_method,
- "payment_method"
- ).to.not.be.null;
- expect(
- response.body.customer_payment_methods[0].payment_method_type,
- "payment_method_type"
- ).to.not.be.null;
+
+ // Validate other payment method properties
+ for (const arrayCount in response.body.customer_payment_methods) {
+ const paymentMethod =
+ response.body.customer_payment_methods[arrayCount];
+
+ expect(
+ globalState.get("customerId"),
+ `${arrayCount} customer_id`
+ ).to.equal(paymentMethod.customer_id);
+
+ expect(
+ paymentMethod.payment_token,
+ `${arrayCount} payment_token`
+ ).to.include("token_").and.not.be.null;
+
+ expect(
+ paymentMethod.payment_method_id,
+ `${arrayCount} payment_method_id`
+ ).to.include("pm_").and.not.be.null;
+
+ expect(paymentMethod.payment_method, `${arrayCount} payment_method`).to
+ .not.be.null;
+
+ expect(
+ paymentMethod.payment_method_type,
+ `${arrayCount} payment_method_type`
+ ).to.not.be.null;
+
+ expect(paymentMethod.last_used_at, `${arrayCount} last_used_at`).to.not
+ .be.null;
+ }
});
});
});
diff --git a/cypress-tests/cypress/support/redirectionHandler.js b/cypress-tests/cypress/support/redirectionHandler.js
index fe30b5b64b..dfe65c85ef 100644
--- a/cypress-tests/cypress/support/redirectionHandler.js
+++ b/cypress-tests/cypress/support/redirectionHandler.js
@@ -7,11 +7,14 @@ const CONSTANTS = {
TIMEOUT: 20000, // 20 seconds
WAIT_TIME: 10000, // 10 seconds
ERROR_PATTERNS: [
- /4\d{2}/,
- /5\d{2}/,
- /error/i,
- /invalid request/i,
- /server error/i,
+ /^(4|5)\d{2}\s/, // HTTP error status codes
+ /\berror occurred\b/i,
+ /\bpayment failed\b/i,
+ /\binvalid request\b/i,
+ /\bserver error\b/i,
+ /\btransaction failed\b/i,
+ /\bpayment declined\b/i,
+ /\bauthorization failed\b/i,
],
VALID_TERMINAL_STATUSES: [
"failed",
@@ -31,28 +34,28 @@ export function handleRedirection(
switch (redirectionType) {
case "bank_redirect":
bankRedirectRedirection(
- urls.redirection_url,
- urls.expected_url,
+ urls.redirectionUrl,
+ urls.expectedUrl,
connectorId,
paymentMethodType
);
break;
case "bank_transfer":
bankTransferRedirection(
- urls.redirection_url,
- urls.expected_url,
+ urls.redirectionUrl,
+ urls.expectedUrl,
connectorId,
paymentMethodType,
- handlerMetadata.next_action_type
+ handlerMetadata.nextActionType
);
break;
case "three_ds":
- threeDsRedirection(urls.redirection_url, urls.expected_url, connectorId);
+ threeDsRedirection(urls.redirectionUrl, urls.expectedUrl, connectorId);
break;
case "upi":
upiRedirection(
- urls.redirection_url,
- urls.expected_url,
+ urls.redirectionUrl,
+ urls.expectedUrl,
connectorId,
paymentMethodType
);
@@ -476,13 +479,18 @@ function verifyReturnUrl(redirectionUrl, expectedUrl, forwardFlow) {
if (!pageText) {
// eslint-disable-next-line cypress/assertion-before-screenshot
cy.screenshot("blank-page-error");
- } else if (
- constants.ERROR_PATTERNS.some((pattern) =>
+ } else {
+ // Check if any error pattern exists in the text
+ const hasError = constants.ERROR_PATTERNS.some((pattern) =>
pattern.test(pageText)
- )
- ) {
- // eslint-disable-next-line cypress/assertion-before-screenshot
- cy.screenshot(`error-page-${Date.now()}`);
+ );
+
+ if (hasError) {
+ // Only take screenshot if an error pattern was found
+ // eslint-disable-next-line cypress/assertion-before-screenshot
+ cy.screenshot(`error-page-${Date.now()}`);
+ throw new Error(`Page contains error: ${pageText}`);
+ }
}
});
diff --git a/cypress-tests/package-lock.json b/cypress-tests/package-lock.json
index abb5bd3cec..28a60cf402 100644
--- a/cypress-tests/package-lock.json
+++ b/cypress-tests/package-lock.json
@@ -9,16 +9,16 @@
"version": "1.0.0",
"license": "ISC",
"devDependencies": {
- "@eslint/js": "^9.19.0",
- "cypress": "^14.0.0",
+ "@eslint/js": "^9.20.0",
+ "cypress": "^14.0.3",
"cypress-mochawesome-reporter": "^3.8.2",
- "eslint": "^9.19.0",
+ "eslint": "^9.20.1",
"eslint-config-prettier": "^10.0.1",
"eslint-plugin-cypress": "^4.1.0",
"eslint-plugin-prettier": "^5.2.3",
- "globals": "^15.14.0",
+ "globals": "^15.15.0",
"jsqr": "^1.4.0",
- "prettier": "^3.4.2"
+ "prettier": "^3.5.1"
}
},
"node_modules/@colors/colors": {
@@ -33,9 +33,9 @@
}
},
"node_modules/@cypress/request": {
- "version": "3.0.6",
- "resolved": "https://registry.npmjs.org/@cypress/request/-/request-3.0.6.tgz",
- "integrity": "sha512-fi0eVdCOtKu5Ed6+E8mYxUF6ZTFJDZvHogCBelM0xVXmrDEkyM22gRArQzq1YcHPm1V47Vf/iAD+WgVdUlJCGg==",
+ "version": "3.0.7",
+ "resolved": "https://registry.npmjs.org/@cypress/request/-/request-3.0.7.tgz",
+ "integrity": "sha512-LzxlLEMbBOPYB85uXrDqvD4MgcenjRBLIns3zyhx7vTPj/0u2eQhzXvPiGcaJrV38Q9dbkExWp6cOHPJ+EtFYg==",
"dev": true,
"license": "Apache-2.0",
"dependencies": {
@@ -52,7 +52,7 @@
"json-stringify-safe": "~5.0.1",
"mime-types": "~2.1.19",
"performance-now": "^2.1.0",
- "qs": "6.13.0",
+ "qs": "6.13.1",
"safe-buffer": "^5.1.2",
"tough-cookie": "^5.0.0",
"tunnel-agent": "^0.6.0",
@@ -191,9 +191,9 @@
}
},
"node_modules/@eslint/js": {
- "version": "9.19.0",
- "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.19.0.tgz",
- "integrity": "sha512-rbq9/g38qjfqFLOVPvwjIvFFdNziEC5S65jmjPw5r6A//QH+W91akh9irMwjDN8zKUTak6W9EsAv4m/7Wnw0UQ==",
+ "version": "9.20.0",
+ "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.20.0.tgz",
+ "integrity": "sha512-iZA07H9io9Wn836aVTytRaNqh00Sad+EamwOVJT12GTLw1VGMFV/4JaME+JjLtr9fiGaoWgYnS54wrfWsSs4oQ==",
"dev": true,
"license": "MIT",
"engines": {
@@ -717,18 +717,29 @@
"node": ">=6"
}
},
- "node_modules/call-bind": {
- "version": "1.0.7",
- "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.7.tgz",
- "integrity": "sha512-GHTSNSYICQ7scH7sZ+M2rFopRoLh8t2bLSW6BbgrtLsahOIB5iyAVJf9GjWK3cYTDaMj4XdBpM1cA6pIS0Kv2w==",
+ "node_modules/call-bind-apply-helpers": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz",
+ "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==",
"dev": true,
"license": "MIT",
"dependencies": {
- "es-define-property": "^1.0.0",
"es-errors": "^1.3.0",
- "function-bind": "^1.1.2",
- "get-intrinsic": "^1.2.4",
- "set-function-length": "^1.2.1"
+ "function-bind": "^1.1.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/call-bound": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.3.tgz",
+ "integrity": "sha512-YTd+6wGlNlPxSuri7Y6X8tY2dmm12UMH66RpKMhiX6rsk5wXXnYgbUcOt8kiS31/AjfoTOvCsE+w8nZQLQnzHA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "call-bind-apply-helpers": "^1.0.1",
+ "get-intrinsic": "^1.2.6"
},
"engines": {
"node": ">= 0.4"
@@ -1023,14 +1034,14 @@
}
},
"node_modules/cypress": {
- "version": "14.0.0",
- "resolved": "https://registry.npmjs.org/cypress/-/cypress-14.0.0.tgz",
- "integrity": "sha512-kEGqQr23so5IpKeg/dp6GVi7RlHx1NmW66o2a2Q4wk9gRaAblLZQSiZJuDI8UMC4LlG5OJ7Q6joAiqTrfRNbTw==",
+ "version": "14.0.3",
+ "resolved": "https://registry.npmjs.org/cypress/-/cypress-14.0.3.tgz",
+ "integrity": "sha512-yIdvobANw3kS+KF/t5vwjjPNufBA8ux7iQHaWxPTkUw2yCKI72m9mKM24eOwE84Wk4ALPsSvEcGbDrwgmhr4RA==",
"dev": true,
"hasInstallScript": true,
"license": "MIT",
"dependencies": {
- "@cypress/request": "^3.0.6",
+ "@cypress/request": "^3.0.7",
"@cypress/xvfb": "^1.2.4",
"@types/sinonjs__fake-timers": "8.1.1",
"@types/sizzle": "^2.3.2",
@@ -1201,24 +1212,6 @@
"dev": true,
"license": "MIT"
},
- "node_modules/define-data-property": {
- "version": "1.1.4",
- "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz",
- "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "es-define-property": "^1.0.0",
- "es-errors": "^1.3.0",
- "gopd": "^1.0.1"
- },
- "engines": {
- "node": ">= 0.4"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
"node_modules/delayed-stream": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
@@ -1239,6 +1232,21 @@
"node": ">=0.3.1"
}
},
+ "node_modules/dunder-proto": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz",
+ "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "call-bind-apply-helpers": "^1.0.1",
+ "es-errors": "^1.3.0",
+ "gopd": "^1.2.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
"node_modules/ecc-jsbn": {
"version": "0.1.2",
"resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz",
@@ -1282,14 +1290,11 @@
}
},
"node_modules/es-define-property": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.0.tgz",
- "integrity": "sha512-jxayLKShrEqqzJ0eumQbVhTYQM27CfT1T35+gCgDFoL82JLsXqTJ76zv6A0YLOgEnLUMvLzsDsGIrl8NFpT2gQ==",
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz",
+ "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==",
"dev": true,
"license": "MIT",
- "dependencies": {
- "get-intrinsic": "^1.2.4"
- },
"engines": {
"node": ">= 0.4"
}
@@ -1304,6 +1309,35 @@
"node": ">= 0.4"
}
},
+ "node_modules/es-object-atoms": {
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz",
+ "integrity": "sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "es-errors": "^1.3.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
+ "node_modules/es-set-tostringtag": {
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz",
+ "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "es-errors": "^1.3.0",
+ "get-intrinsic": "^1.2.6",
+ "has-tostringtag": "^1.0.2",
+ "hasown": "^2.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
"node_modules/escalade": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.2.0.tgz",
@@ -1335,18 +1369,18 @@
}
},
"node_modules/eslint": {
- "version": "9.19.0",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.19.0.tgz",
- "integrity": "sha512-ug92j0LepKlbbEv6hD911THhoRHmbdXt2gX+VDABAW/Ir7D3nqKdv5Pf5vtlyY6HQMTEP2skXY43ueqTCWssEA==",
+ "version": "9.20.1",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.20.1.tgz",
+ "integrity": "sha512-m1mM33o6dBUjxl2qb6wv6nGNwCAsns1eKtaQ4l/NPHeTvhiUPbtdfMyktxN4B3fgHIgsYh1VT3V9txblpQHq+g==",
"dev": true,
"license": "MIT",
"dependencies": {
"@eslint-community/eslint-utils": "^4.2.0",
"@eslint-community/regexpp": "^4.12.1",
"@eslint/config-array": "^0.19.0",
- "@eslint/core": "^0.10.0",
+ "@eslint/core": "^0.11.0",
"@eslint/eslintrc": "^3.2.0",
- "@eslint/js": "9.19.0",
+ "@eslint/js": "9.20.0",
"@eslint/plugin-kit": "^0.2.5",
"@humanfs/node": "^0.16.6",
"@humanwhocodes/module-importer": "^1.0.1",
@@ -1481,6 +1515,19 @@
"url": "https://opencollective.com/eslint"
}
},
+ "node_modules/eslint/node_modules/@eslint/core": {
+ "version": "0.11.0",
+ "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.11.0.tgz",
+ "integrity": "sha512-DWUB2pksgNEb6Bz2fggIy1wh6fGgZP4Xyy/Mt0QZPiloKKXerbqq9D3SBQTlCRYOrcRPu4vuz+CGjwdfqxnoWA==",
+ "dev": true,
+ "license": "Apache-2.0",
+ "dependencies": {
+ "@types/json-schema": "^7.0.15"
+ },
+ "engines": {
+ "node": "^18.18.0 || ^20.9.0 || >=21.1.0"
+ }
+ },
"node_modules/espree": {
"version": "10.3.0",
"resolved": "https://registry.npmjs.org/espree/-/espree-10.3.0.tgz",
@@ -1778,14 +1825,15 @@
}
},
"node_modules/form-data": {
- "version": "4.0.1",
- "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.1.tgz",
- "integrity": "sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==",
+ "version": "4.0.2",
+ "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.2.tgz",
+ "integrity": "sha512-hGfm/slu0ZabnNt4oaRZ6uREyfCj6P4fT/n6A1rGV+Z0VdGXjfOhVUpkn6qVQONHGIFwmveGXyDs75+nr6FM8w==",
"dev": true,
"license": "MIT",
"dependencies": {
"asynckit": "^0.4.0",
"combined-stream": "^1.0.8",
+ "es-set-tostringtag": "^2.1.0",
"mime-types": "^2.1.12"
},
"engines": {
@@ -1859,17 +1907,22 @@
}
},
"node_modules/get-intrinsic": {
- "version": "1.2.4",
- "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.4.tgz",
- "integrity": "sha512-5uYhsJH8VJBTv7oslg4BznJYhDoRI6waYCxMmCdnTrcCrHA/fCFKoTFz2JKKE0HdDFUF7/oQuhzumXJK7paBRQ==",
+ "version": "1.2.7",
+ "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.7.tgz",
+ "integrity": "sha512-VW6Pxhsrk0KAOqs3WEd0klDiF/+V7gQOpAvY1jVU/LHmaD/kQO4523aiJuikX/QAKYiW6x8Jh+RJej1almdtCA==",
"dev": true,
"license": "MIT",
"dependencies": {
+ "call-bind-apply-helpers": "^1.0.1",
+ "es-define-property": "^1.0.1",
"es-errors": "^1.3.0",
+ "es-object-atoms": "^1.0.0",
"function-bind": "^1.1.2",
- "has-proto": "^1.0.1",
- "has-symbols": "^1.0.3",
- "hasown": "^2.0.0"
+ "get-proto": "^1.0.0",
+ "gopd": "^1.2.0",
+ "has-symbols": "^1.1.0",
+ "hasown": "^2.0.2",
+ "math-intrinsics": "^1.1.0"
},
"engines": {
"node": ">= 0.4"
@@ -1878,6 +1931,20 @@
"url": "https://github.com/sponsors/ljharb"
}
},
+ "node_modules/get-proto": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz",
+ "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "dunder-proto": "^1.0.1",
+ "es-object-atoms": "^1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
"node_modules/get-stream": {
"version": "5.2.0",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz",
@@ -1991,9 +2058,9 @@
}
},
"node_modules/globals": {
- "version": "15.14.0",
- "resolved": "https://registry.npmjs.org/globals/-/globals-15.14.0.tgz",
- "integrity": "sha512-OkToC372DtlQeje9/zHIo5CT8lRP/FUgEOKBEhU4e0abL7J7CD24fD9ohiLN5hagG/kWCYj4K5oaxxtj2Z0Dig==",
+ "version": "15.15.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-15.15.0.tgz",
+ "integrity": "sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==",
"dev": true,
"license": "MIT",
"engines": {
@@ -2004,13 +2071,13 @@
}
},
"node_modules/gopd": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz",
- "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==",
+ "version": "1.2.0",
+ "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz",
+ "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==",
"dev": true,
"license": "MIT",
- "dependencies": {
- "get-intrinsic": "^1.1.3"
+ "engines": {
+ "node": ">= 0.4"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
@@ -2033,23 +2100,10 @@
"node": ">=8"
}
},
- "node_modules/has-property-descriptors": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz",
- "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "es-define-property": "^1.0.0"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
- "node_modules/has-proto": {
- "version": "1.0.3",
- "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.3.tgz",
- "integrity": "sha512-SJ1amZAJUiZS+PhsVLf5tGydlaVB8EdFpaSO4gmiUKUOxk8qzn5AIy4ZeJUmh22znIdk/uMAUT2pl3FxzVUH+Q==",
+ "node_modules/has-symbols": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz",
+ "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==",
"dev": true,
"license": "MIT",
"engines": {
@@ -2059,12 +2113,15 @@
"url": "https://github.com/sponsors/ljharb"
}
},
- "node_modules/has-symbols": {
- "version": "1.0.3",
- "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz",
- "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==",
+ "node_modules/has-tostringtag": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz",
+ "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==",
"dev": true,
"license": "MIT",
+ "dependencies": {
+ "has-symbols": "^1.0.3"
+ },
"engines": {
"node": ">= 0.4"
},
@@ -2668,6 +2725,16 @@
"loose-envify": "cli.js"
}
},
+ "node_modules/math-intrinsics": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz",
+ "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==",
+ "dev": true,
+ "license": "MIT",
+ "engines": {
+ "node": ">= 0.4"
+ }
+ },
"node_modules/merge-stream": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz",
@@ -3169,9 +3236,9 @@
}
},
"node_modules/object-inspect": {
- "version": "1.13.3",
- "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.3.tgz",
- "integrity": "sha512-kDCGIbxkDSXE3euJZZXzc6to7fCrKHNI/hSRQnRuQ+BWjFNzZwiFF8fj/6o2t2G9/jTj8PSIYTfCLelLZEeRpA==",
+ "version": "1.13.4",
+ "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz",
+ "integrity": "sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==",
"dev": true,
"license": "MIT",
"engines": {
@@ -3392,9 +3459,9 @@
}
},
"node_modules/prettier": {
- "version": "3.4.2",
- "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.4.2.tgz",
- "integrity": "sha512-e9MewbtFo+Fevyuxn/4rrcDAaq0IYxPGLvObpQjiZBMAzB9IGmzlnG9RZy3FFas+eBMu2vA0CszMeduow5dIuQ==",
+ "version": "3.5.1",
+ "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.5.1.tgz",
+ "integrity": "sha512-hPpFQvHwL3Qv5AdRvBFMhnKo4tYxp0ReXiPn2bxkiohEX6mBeBwEpBSQTkD458RaaDKQMYSp4hX4UtfUTA5wDw==",
"dev": true,
"license": "MIT",
"bin": {
@@ -3484,9 +3551,9 @@
}
},
"node_modules/qs": {
- "version": "6.13.0",
- "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz",
- "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==",
+ "version": "6.13.1",
+ "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.1.tgz",
+ "integrity": "sha512-EJPeIn0CYrGu+hli1xilKAPXODtJ12T0sP63Ijx2/khC2JtuaN3JyNIpvmnkmaEtha9ocbG4A4cMcr+TvqvwQg==",
"dev": true,
"license": "BSD-3-Clause",
"dependencies": {
@@ -3658,24 +3725,6 @@
"dev": true,
"license": "ISC"
},
- "node_modules/set-function-length": {
- "version": "1.2.2",
- "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz",
- "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "define-data-property": "^1.1.4",
- "es-errors": "^1.3.0",
- "function-bind": "^1.1.2",
- "get-intrinsic": "^1.2.4",
- "gopd": "^1.0.1",
- "has-property-descriptors": "^1.0.2"
- },
- "engines": {
- "node": ">= 0.4"
- }
- },
"node_modules/shebang-command": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
@@ -3700,16 +3749,73 @@
}
},
"node_modules/side-channel": {
- "version": "1.0.6",
- "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.6.tgz",
- "integrity": "sha512-fDW/EZ6Q9RiO8eFG8Hj+7u/oW+XrPTIChwCOM2+th2A6OblDtYYIpve9m+KvI9Z4C9qSEXlaGR6bTEYHReuglA==",
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.0.tgz",
+ "integrity": "sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==",
"dev": true,
"license": "MIT",
"dependencies": {
- "call-bind": "^1.0.7",
"es-errors": "^1.3.0",
- "get-intrinsic": "^1.2.4",
- "object-inspect": "^1.13.1"
+ "object-inspect": "^1.13.3",
+ "side-channel-list": "^1.0.0",
+ "side-channel-map": "^1.0.1",
+ "side-channel-weakmap": "^1.0.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/side-channel-list": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.0.tgz",
+ "integrity": "sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "es-errors": "^1.3.0",
+ "object-inspect": "^1.13.3"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/side-channel-map": {
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz",
+ "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "call-bound": "^1.0.2",
+ "es-errors": "^1.3.0",
+ "get-intrinsic": "^1.2.5",
+ "object-inspect": "^1.13.3"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
+ "node_modules/side-channel-weakmap": {
+ "version": "1.0.2",
+ "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz",
+ "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==",
+ "dev": true,
+ "license": "MIT",
+ "dependencies": {
+ "call-bound": "^1.0.2",
+ "es-errors": "^1.3.0",
+ "get-intrinsic": "^1.2.5",
+ "object-inspect": "^1.13.3",
+ "side-channel-map": "^1.0.1"
},
"engines": {
"node": ">= 0.4"
@@ -3885,22 +3991,22 @@
"license": "MIT"
},
"node_modules/tldts": {
- "version": "6.1.64",
- "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.64.tgz",
- "integrity": "sha512-ph4AE5BXWIOsSy9stpoeo7bYe/Cy7VfpciIH4RhVZUPItCJmhqWCN0EVzxd8BOHiyNb42vuJc6NWTjJkg91Tuw==",
+ "version": "6.1.77",
+ "resolved": "https://registry.npmjs.org/tldts/-/tldts-6.1.77.tgz",
+ "integrity": "sha512-lBpoWgy+kYmuXWQ83+R7LlJCnsd9YW8DGpZSHhrMl4b8Ly/1vzOie3OdtmUJDkKxcgRGOehDu5btKkty+JEe+g==",
"dev": true,
"license": "MIT",
"dependencies": {
- "tldts-core": "^6.1.64"
+ "tldts-core": "^6.1.77"
},
"bin": {
"tldts": "bin/cli.js"
}
},
"node_modules/tldts-core": {
- "version": "6.1.64",
- "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.64.tgz",
- "integrity": "sha512-uqnl8vGV16KsyflHOzqrYjjArjfXaU6rMPXYy2/ZWoRKCkXtghgB4VwTDXUG+t0OTGeSewNAG31/x1gCTfLt+Q==",
+ "version": "6.1.77",
+ "resolved": "https://registry.npmjs.org/tldts-core/-/tldts-core-6.1.77.tgz",
+ "integrity": "sha512-bCaqm24FPk8OgBkM0u/SrEWJgHnhBWYqeBo6yUmcZJDCHt/IfyWBb+14CXdGi4RInMv4v7eUAin15W0DoA+Ytg==",
"dev": true,
"license": "MIT"
},
@@ -3929,9 +4035,9 @@
}
},
"node_modules/tough-cookie": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.0.0.tgz",
- "integrity": "sha512-FRKsF7cz96xIIeMZ82ehjC3xW2E+O2+v11udrDYewUbszngYhsGa8z6YUMMzO9QJZzzyd0nGGXnML/TReX6W8Q==",
+ "version": "5.1.1",
+ "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-5.1.1.tgz",
+ "integrity": "sha512-Ek7HndSVkp10hmHP9V4qZO1u+pn1RU5sI0Fw+jCU3lyvuMZcgqsNgc6CmJJZyByK4Vm/qotGRJlfgAX8q+4JiA==",
"dev": true,
"license": "BSD-3-Clause",
"dependencies": {
diff --git a/cypress-tests/package.json b/cypress-tests/package.json
index b3701ce8fc..22c3e1bbc9 100644
--- a/cypress-tests/package.json
+++ b/cypress-tests/package.json
@@ -20,15 +20,15 @@
"author": "Hyperswitch",
"license": "ISC",
"devDependencies": {
- "@eslint/js": "^9.19.0",
- "cypress": "^14.0.0",
+ "@eslint/js": "^9.20.0",
+ "cypress": "^14.0.3",
"cypress-mochawesome-reporter": "^3.8.2",
- "eslint": "^9.19.0",
+ "eslint": "^9.20.1",
"eslint-config-prettier": "^10.0.1",
"eslint-plugin-cypress": "^4.1.0",
"eslint-plugin-prettier": "^5.2.3",
- "globals": "^15.14.0",
+ "globals": "^15.15.0",
"jsqr": "^1.4.0",
- "prettier": "^3.4.2"
+ "prettier": "^3.5.1"
}
}