testcafe icon indicating copy to clipboard operation
testcafe copied to clipboard

Error when I add Wait time of 5 secs to my test

Open anilchinnu21 opened this issue 9 years ago • 2 comments

Are you requesting a feature or reporting a bug?

Bug

What is the current behavior?

Getting the below error as soon as I add wait time of 5 sec to my test. "Uncaught RangeError: Maximum call stack size exceeded"

What is the expected behavior?

I thought it should add a delay at the step for 5 sec and then continue execution without error.

How would you reproduce the current behavior (if this is a bug)?

Please see the test code below.

Provide the test code and the tested page URL (if applicable)

Tested page URL:

Test code

test('My first test', async t => {
    const field = await Selector('#username');
    await t
        .typeText('#username', 'xxxx')
        .typeText('#password', 'xxxxx')
        .click('#btn_login')
        .wait(5000)
        .expect(Selector('#userProfile_userFullName_1').innerText).eql('xxxxx')
        .navigateTo('/nextpage')
        .wait(5000)
        .expect(Selector('#myHolidayListHeader_1')).ok();
});

Specify your

  • operating system: Chrome 60.0.3112 / Windows 10 0.0.0
  • testcafe version:0.17.1
  • node.js version: 8.0.0

anilchinnu21 avatar Sep 18 '17 11:09 anilchinnu21

Hi @anilchinnu21,

It seems the issue is specific for your page. At first, please check does your page have js-errors in the console in the Developers tools if you open it and perform test steps manually. Then, provide as with a full test report with an error callstack. And provide us with an url to your tested page if possible.

AlexanderMoskovkin avatar Sep 18 '17 13:09 AlexanderMoskovkin

Any updates here?

AlexanderMoskovkin avatar Oct 12 '17 09:10 AlexanderMoskovkin