Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3DS page loading issue and switching into iframe issue in cross domain using different versions of Testcafe v2.3.0 and Testcafe v3.3.0 #8048

Closed
chaithanyvv opened this issue Oct 19, 2023 · 2 comments
Labels
STATE: Need clarification An issue lacks information for further research. TYPE: bug The described behavior is considered as wrong (bug).

Comments

@chaithanyvv
Copy link

What is your Scenario?

Scenario 1 : Testcafe 3.3.0
Our application involves 3DS validation page where we were using Testcafe 3.3.0 . We are unable to load 3DS page using Testcafe as the hammerhead proxy is blocking the components from loading. Our page structure contains cross domains as below -
top : domain1.com
output_frame : domain2.com
stepUpIframe : domain2.com

Scenario 2 : Testcafe 2.3.0
Our application involves 3DS validation page where we were using Testcafe 2.3.0 . We are unable to switch to the stepUp iframe input field to enter the authentication. Our page structure contains cross domains as below -
top : domain1.com
output_frame : domain2.com
stepUpIframe : domain2.com

What is the Current behavior?

Scenario 1: Testcafe 3.3.0
We are unable to load 3DS page using Testcafe as the hammerhead proxy is blocking the components from loading. We have tried with native automation and without native automation. And also with our organization level proxies.

Scenario 2: Testcafe 2.3.0
We are unable to switch to the stepUp iframe input field to enter the authentication.

3DS issue _screenshot1
3DS issue _screenshot2

What is the Expected behavior?

WE should be able to switch to the iframe and enter the input fields .

What is your public website URL? (or attach your complete example)

domain1.com

What is your TestCafe test code?

import { Selector , ClientFunction } from 'testcafe'; // first import testcafe selectors

fixture Getting Started// declare the fixture
.page ``; // specify the start page

//then create a test and place your code within it
test('My first test', async t => {
await t
.click(Selector(''));

	await t.click(Selector(')')).wait(3000);
    await t.switchToIframe(Selector('#output_frame'));
    await t.click(Selector('#card-registered-yes').filterVisible())
        
        .typeText(Selector('#cardholderName'), '')
        .switchToIframe(Selector('#card-number-element > iframe'))
         .typeText(Selector('input[id="number"]'), '', { replace: true })
        .switchToMainWindow()
        .switchToIframe(Selector('#output_frame'))
        .typeText(Selector('#creditCardExpiryDateMonth'), '')
        .typeText(Selector('#creditCardExpiryDateYear'), '')
        .switchToIframe(Selector('#card-cvc-element > iframe'))
        .click(Selector('input[id="securityCode"]'))
        .typeText(Selector('input[id="securityCode"]'), '', { replace: true })
        .switchToMainWindow()
        .switchToIframe(Selector('#output_frame')).wait(3000)
        .scrollIntoView(Selector('#cof-yes-button'))
        .click(Selector('#cof-yes-button'))
        

       
            await t.wait(3000)
            .scrollIntoView(Selector('button[id="pay-btn"]'))
       .click(Selector('button[id="pay-btn"]'))
       .doubleClick(Selector('button[id="pay-btn"]'));

       await t.switchToMainWindow();
       await t.wait(5000)
       .switchToIframe(Selector('#output_frame' , {timeout : 60000}));
       
       await t.switchToIframe(Selector('iframe[id*="StepUpIframe"]',{timeout : 120000}));
       await t.wait(30000);

       const s = Selector('html > body > div > #content').find('input.input-field').with({ visibilityCheck : true})
       await t.click(s);
       await t.typeText(s,'');
       await t.expect(Selector('html > body > div > #content ').find('input.input-field').visible).ok();
        await t.wait(5000);
        await t.click(Selector('html > body > div > #content').find('input.input-field'));

        await t.click(Selector('input[value="SUBMIT"]'))
        .wait(10000)
        .switchToMainWindow();                 

});

Note: we have removed all the locators and sensitive info as we cannot expose the actual code

Your complete configuration file

{
"skipJsErrors": true,
"experimentalProxyless":true,
"disableCrossDomain":true,
"bypassProxy": [
"localhost",
"payment.localhost"

 ]

}

Your complete test report

No response

Screenshots

3DS issue _screenshot1
3DS issue _screenshot2

Steps to Reproduce

1.same as described above
2.
3.

TestCafe version

3.3.0 and 2.3.0

Node.js version

16 and 18

Command-line arguments

testcafe chrome testing.js

Browser name(s) and version(s)

No response

Platform(s) and version(s)

No response

Other

No response

@chaithanyvv chaithanyvv added the TYPE: bug The described behavior is considered as wrong (bug). label Oct 19, 2023
@need-response-app need-response-app bot added the STATE: Need response An issue that requires a response or attention from the team. label Oct 19, 2023
@aleks-pro aleks-pro added the STATE: Need simple sample A simple sample is required to examine the issue. label Oct 25, 2023
@github-actions
Copy link

Thank you for submitting a bug report. We would love to help you investigate the issue. Please share a simple code example that reliably reproduces the bug. For more information, read the following article: How To Create a Minimal Working Example When You Submit an Issue. We look forward to your response.

@github-actions github-actions bot added STATE: Need clarification An issue lacks information for further research. and removed STATE: Need response An issue that requires a response or attention from the team. STATE: Need simple sample A simple sample is required to examine the issue. labels Oct 25, 2023
Copy link

github-actions bot commented Nov 4, 2023

This issue was automatically closed because there was no response to our request for more information from the original author. Currently, we don't have enough information to take action. Please reach out to us if you find the necessary information and are able to share it. We are also eager to know if you resolved the issue on your own and can share your findings with everyone.

@github-actions github-actions bot closed this as completed Nov 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
STATE: Need clarification An issue lacks information for further research. TYPE: bug The described behavior is considered as wrong (bug).
Projects
None yet
Development

No branches or pull requests

2 participants