Skip to content
18 changes: 18 additions & 0 deletions cypress-tests/cypress/e2e/cvc-checks-e2e-test.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,4 +122,22 @@ describe("Card CVC Checks", () => {
.should("have.value", "1234");
});
});

it("should display an error when CVC is empty for a saved card", () => {
cy.wait(2000);

getIframeBody()
.contains("div", "4 digit cvc t..")
.should("exist")
.click();
cy.wait(1000);

getIframeBody().get("#submit").click();

getIframeBody()
.contains("CVC Number cannot be empty")
.should("be.visible");

cy.contains("Please enter all fields").should("be.visible");
});
});
19 changes: 19 additions & 0 deletions cypress-tests/cypress/e2e/external-3DS-netcetera-e2e-test.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import * as testIds from "../../../src/Utilities/TestUtils.bs";
import {
getClientURL,
netceteraChallengeTestCard,
netceteraFrictionlessTestCard,
createPaymentBody,
changeObjectKeyValue,
connectorProfileIdMapping,
Expand Down Expand Up @@ -96,4 +97,22 @@ describe("External 3DS using Netcetera Checks", () => {
);
});
});

it("If the user enters a frictionless card, the payment should be successful without a challenge.", () => {
cy.wait(2000);
getIframeBody().find(`[data-testid=${testIds.addNewCardIcon}]`).click();
getIframeBody()
.find(`[data-testid=${testIds.cardNoInputTestId}]`)
.type(netceteraFrictionlessTestCard);
getIframeBody()
.find(`[data-testid=${testIds.expiryInputTestId}]`)
.type("0444");
cy.wait(1000);
getIframeBody()
.find(`[data-testid=${testIds.cardCVVInputTestId}]`)
.type("1234");
getIframeBody().get("#submit").click();
cy.wait(4000);
cy.contains("Thanks for your order!").should("be.visible");
});
});
1 change: 1 addition & 0 deletions cypress-tests/cypress/support/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,3 +142,4 @@ export const bluesnapTestCard = "4000000000001091";
export const amexTestCard = "378282246310005";
export const visaTestCard = "4242424242424242";
export const netceteraChallengeTestCard = "348638267931507";
export const netceteraFrictionlessTestCard = "4929251897047956";
Loading