Test#keyEvent()

keyEvent (selector, type, keyCode) RSVP.Promisepublic

Defined in packages/ember-testing/lib/helpers.js:64
Available since 1.5.0

Simulates a key event, e.g. keypress, keydown, keyup with the desired keyCode

Example:

keyEvent('.some-jQuery-selector', 'keypress', 13).then(function() {
 // assert something
});

Parameters:

selector String
jQuery selector for finding element on the DOM
type String
the type of key event, e.g. `keypress`, `keydown`, `keyup`
keyCode Number
the keyCode of the simulated key event

Returns:

RSVP.Promise
doc_EmberJs
2016-11-30 16:53:41
Comments
Leave a Comment

Please login to continue.