testcafe icon indicating copy to clipboard operation
testcafe copied to clipboard

Add Scroll Actions to set of user Actions

Open switch201 opened this issue 7 years ago • 2 comments

What is your Test Scenario?

IN many cases It could be useful to have the suer scroll explicitly. In some applications there are events and such triggered by the act of scrolling. It also helps when there are edge cases of testcafe not scrolling correctly. In some instance I want to offset the scroll based because there might be a footer element in the way for example.

What are you suggesting?

I am suggesting that Scrolling be added as a user action that can be called explicitly. It could take 2 argument types. if a Selector is passed in then it will scroll to that selector. If numbers are input it will attempt to scroll that many pixels (or whatever unit of measurement you want) In the X and Y directions.

What alternatives have you considered?

Right now I just have to send mouse and key board events directly in. For example for scrolling down I just tell the program to press the down key, but this doesn't work if a textbox is selected for example.

Additional context

This is something that is built into other frame works I don't think its too crazy of an ask. I know that all user actions in testcafe should auto scroll, but I do find cases where this doesn't always work.

On the one hand I could submit a bug report for said issues, but I can't share my app as an example so I already for see it being closed as can not reproduce.

switch201 avatar Oct 17 '19 19:10 switch201

Hello, Take a look at this issue: https://github.com/DevExpress/testcafe/issues/527. Could you please describe your scenario there in greater detail?

By the way, TestCafe can automatically scroll the page to click element at the bottom. If it does not work in your test, please provide us with a simple code snippet so that we can reproduce the issue.

Dmitry-Ostashev avatar Oct 18 '19 09:10 Dmitry-Ostashev

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.

no-response[bot] avatar Oct 28 '19 09:10 no-response[bot]