selenium-ide icon indicating copy to clipboard operation
selenium-ide copied to clipboard

Edit content command executed however content not filled on the ckeditor5 box

Open nomanul-chowdhury opened this issue 1 year ago • 6 comments

🐛 Bug Report

Edit content command executed however content not filled up in the ckeditor5 box

To Reproduce

  • Go to https://ckeditor.com/docs/ckeditor5/latest/features/link.html
  • In the demo section ck editor5 box delete the content then start record tests using selenium ide chrome extension
  • Go to the demo ckeditor 5 box and type something any text
  • Then stop recording then play the test

Actual behavior

Its not typing on the ckeditor5 box. Previous version of ck editor4 worked no issue. Recently my organization upgraded ckeditor5. There all our tests cases in selenium ide failing as we are using ckeditor5 acroll all content in our webpage via cms. Very basic command is failing

Expected behavior

As it recorded correctly when test run it should type inside ck editor 5

Environment

Windows 10, Chrome and Edge browser selenium ide extension 3.17.0 Selenium ide chrome extension 3.17.0

Screenshot

image

nomanul-chowdhury avatar Feb 05 '24 03:02 nomanul-chowdhury

Ah! Good call, I think this was originally done in such a way to play nicely with js execution. Nowadays, I think we should be able to just record clicks and use send keys and such.

toddtarsi avatar Feb 05 '24 13:02 toddtarsi

@toddtarsi is there any work around ?

nomanul-chowdhury avatar Feb 05 '24 23:02 nomanul-chowdhury

@nomanul-chowdhury - I think if you find the right element to interact with, you can usually just instead do send_keys against that element. It can be hard to find the right element to do that, so I'd recommend opening the dev tools inspector (right click will have a menu option for this in playback), and use some of the element inspector widgets to find out what needs the keystrokes. With how events bubble here, it can be kinda obnoxious, but you'll eventually get it.

toddtarsi avatar Feb 06 '24 13:02 toddtarsi

Thanks @toddtarsi

nomanul-chowdhury avatar Feb 06 '24 23:02 nomanul-chowdhury

Absolutely, sorry I can't do more in the moment. Tbh I hate the recorder trying to write the html on content editables. I think I'll probably strip that from the recorder, as I don't think any actual content editable supports that use pattern. Instead it should just try and detect capture phase send keys stuff I think. I'll try testing on your provided site later, so lets keep this issue open.

toddtarsi avatar Feb 07 '24 00:02 toddtarsi