How can I do it? I already looked into ionic forum, google results, and didn't find anything useful. Also, I already tried triggering dblclick
, dbltap
, doubletap
, doubleClick
, and even multiple tap
and click
events, but nothing seems to work.
I know some events that I used don't even exist, I was just trying to see if ionic would recognize them somehow. Also, I tried the click events because the app runs just fine in the browser, so I thought it could work in the specs as well.
If it helps, I need this to unit test my feature. I have an ion-list
, and when an user double taps an ion-item
, it marks the item as checked. My markup currently look like this:
<ion-item on-double-tap="ctrl.toggleProductConfirmation(product)" ...
And my spec, like this:
describe('when checking an item', function() {
beforeEach(function() {
this.element.find('ion-item').eq(0).trigger('doubletap');
});
** specs here **
One last detail: I use phantom JS to run my specs.
Thanks for helping!