testcafe icon indicating copy to clipboard operation
testcafe copied to clipboard

typeText containing a space scrolls the page on Safari

Open PierreRott opened this issue 3 years ago • 1 comments

What is your Scenario?

I would like to type text with multiple words (separated by space) inside the input.

What is the Current behavior?

The test which is being run on Safari scrolls the page viewport. Scrolling is obviously caused by space in the string which is passed inside the typeText method. Test behaves correctly on other browsers.

What is the Expected behavior?

It should not scroll the page viewport.

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

<input id="input">
<div style="height: 1000px"></div>
<div>text to check scroll</div>

What is your TestCafe test code?

test('Should not scroll', async () => {
    await t
        .click(Selector('#input'))
        .typeText(Selector('#input'), 'random text');
});

Your complete configuration file

No response

Your complete test report

No response

Screenshots

No response

Steps to Reproduce

  1. run test on Safari where the text with multiple words separated by space is being typed inside the input
  2. observe browser behavior while space is being typed inside the input
  3. check that page viewport is being scrolled

TestCafe version

2.0.1-alpha.1

Node.js version

v14.16.1

Command-line arguments

testcafe remote **.e2e-spec.ts --speed 0.1 --hostname [ip-address] -e

Browser name(s) and version(s)

Safari 15.6.1

Platform(s) and version(s)

macOS Monterey Version 12.5.1

Other

No response

PierreRott avatar Sep 06 '22 13:09 PierreRott

Hi @PierreRott

Thank you for the shared information. I've reproduced the issue.

miherlosev avatar Sep 09 '22 08:09 miherlosev

This issue has been automatically marked as stale because it has not had any activity for a long period. It will be closed and archived if no further activity occurs. However, we may return to this issue in the future. If it still affects you or you have any additional information regarding it, please leave a comment and we will keep it open.

github-actions[bot] avatar Sep 07 '23 01:09 github-actions[bot]

We're closing this issue after a prolonged period of inactivity. If it still affects you, please add a comment to this issue with up-to-date information. Thank you.

github-actions[bot] avatar Sep 17 '23 01:09 github-actions[bot]