sendKeysToPage
See Testing keyboard shortcuts. Sends given keys to a page after focusing the page using the given element. Useful for testing keyboard shortcuts in an application.
sendKeysToPage(elemId, keys, keys, ...)
#
ParameterselemId
: A static element on page that can be clicked to focus on page. Note thatbody
element shouldn't be given as certain browser drivers (webdriver) can't use it for clicking being it's size is 0.keys
:string
keys that needs to be sent to the page.
#
Returns- No value