Testcafe: Method selectText() doesn't work

Created on 7 Jun 2018  路  5Comments  路  Source: DevExpress/testcafe

Method selectText() doesn't work - http://s.csssr.ru/U5LQQCK7T/20180606190308.jpg
Webproject based on React but I use normal css-selectors

  • operating system: Windows 10
  • tetcafe version: 0.20.2
  • node.js version: 6.11.0
Need clarification

Most helpful comment

"testcafe": "^0.21.0",

I've stumbled upon this, and I'm having a trouble with the selectText method

The action element is expected to be editable (an input, textarea or element with the contentEditable attribute).

screen shot 2018-08-23 at 11 42 20

Basically it complains that the input is not editable, where in fact it is.
What I'm trying to achieve is to delete a text from an input field.

await t.selectText(inputElement).pressKey('delete');

I'm able to write to the field, but not select the text.

All 5 comments

Hi @Andrei1982! I've visited the error link and the error message Unable to find element with ID 128 implies that React renderer failed to render an element.

Do you have this error in the browser console without TestCafe? Could you please give me access to the tested page? You can send an email to me for a private discussion.

I will close the issue because no activity has been encountered for a long time.
Feel free to reopen the issue if the problem persists and you can provide an example to reproduce it.

"testcafe": "^0.21.0",

I've stumbled upon this, and I'm having a trouble with the selectText method

The action element is expected to be editable (an input, textarea or element with the contentEditable attribute).

screen shot 2018-08-23 at 11 42 20

Basically it complains that the input is not editable, where in fact it is.
What I'm trying to achieve is to delete a text from an input field.

await t.selectText(inputElement).pressKey('delete');

I'm able to write to the field, but not select the text.

"testcafe": "^0.21.0",

I've stumbled upon this, and I'm having a trouble with the selectText method

The action element is expected to be editable (an input, textarea or element with the contentEditable attribute).

screen shot 2018-08-23 at 11 42 20

Basically it complains that the input is not editable, where in fact it is.
What I'm trying to achieve is to delete a text from an input field.

await t.selectText(inputElement).pressKey('delete');

I'm able to write to the field, but not select the text.

Right now I am having the exact same situation with Testcafe! Was anyone able to solve it?

We need a complete example (a test and a page) to reproduce and debug the issue with the latest TestCafe version. Without it, we won't be able to advance. Please, submit a new bug report and attach a complete example that can be used to reproduce the issue with the latest TestCafe version.

Was this page helpful?
0 / 5 - 0 ratings