Skip to content

fix(cdk/testing): Add support to send keys to conenteditable elements in testbed environment. #19107

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

Closed
wants to merge 1 commit into from

Conversation

ienzam
Copy link
Contributor

@ienzam ienzam commented Apr 18, 2020

Fixes #19102

@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Apr 18, 2020
@mmalerba mmalerba changed the title bug(cdk/testing): Add support to send keys to conenteditable elements in testbed environment. fix(cdk/testing): Add support to send keys to conenteditable elements in testbed environment. Apr 21, 2020
Copy link
Contributor Author

@ienzam ienzam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your review @mmalerba

Sorry for dropping this :(

await inheritEditable.sendKeys('Yi');
// The following expectation is failing on Protractor environment
// In protractor environment, the text is empty.
if (environment == TestEnvironment.TEST_BED) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to figure out why this is failing, not just disable the test

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I understand that. Just wondering if you have any idea why this may be happening.
And even with this happening, if we can't find a solution, can we submit this CL?
(The CL is an improvement over current testbed implementation, this bug already exists in Protractor)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to at least understand what's happening first. If we know why its happening I might be ok with submitting it as is (with a comment explaining).

Does the example work if you run it and manually interact? I'm not sure why its happening, but here are some guesses:

  • Is the click handler on the design mode on button actually firing? Clicking is more finicky in Protractor, it can fail if other elements are overlapping or something like that
  • Maybe it needs some delay before trying to edit? I'm not sure if the browser takes some time to activate design mode

Copy link
Contributor Author

@ienzam ienzam Nov 23, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry I am new here. How can I run the e2e test (as opposed to test) to interact with it to see what's happening?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should be able to run the end to end tests with yarn e2e and the unit tests with yarn test all

@devversion devversion removed their request for review August 18, 2021 12:59
@andrewseguin andrewseguin removed the cla: yes PR author has agreed to Google's Contributor License Agreement label Dec 28, 2021
@andrewseguin
Copy link
Contributor

Closing due to inactivity from the author. If you'd like to continue with this PR, feel free to re-open a new rebased version

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Apr 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug(cdk/testing): sendKeys does not update for contenteditable elements
4 participants