mercredi 6 mai 2015

How to simulate ctrl-click or shift-click with webdriver.io?

With webdriver.io I would like to simulate clicks with a modifier like shift or ctrl. The keys() method seems to do something like that but it's not clear to me how to release a modifier key again and it throws an error when I use 16 (key code for shift) as a parameter for the method. See: http://ift.tt/1QmliB3

Background: In my webpage that I test I have a list of elements that are comparable to files and folders in a file browser and it is possible to select multiple of those with shift and ctrl. This works well and now I would like to test it with webdriver.io. To do this, webdriver.io e.g. has to click on an element, then press shift, then click on an other element and finally release the shift button. Is there any way to do that?

Best,

Sandro

Aucun commentaire:

Enregistrer un commentaire