You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For unit-testing parts of our web application I want to simulate touch events. Could you provide some examples for this? (I am using the HammerJS jQuery plugin and the Jasmine framework).
The text was updated successfully, but these errors were encountered:
Thanks, I looked at the tests and managed to get something working.
Now I have the following problem:
I have a component which binds to the tap event. In the unit test I get the hammer instance by using "element.data('hammer')" and then bind my test function with "hammer.on('tap', ...)". Using "Simulator.gestures.tap(element)" I trigger the gesture. The problem now is that the gesture handler of the component is called after the gesture handler from the test.
Edit: when I use "element.hammer().bind('tap', ..)" instead of "hammer.on" the order is correct. So it seems like the order is different from raw hammerjs and the jquery version.
For unit-testing parts of our web application I want to simulate touch events. Could you provide some examples for this? (I am using the HammerJS jQuery plugin and the Jasmine framework).
The text was updated successfully, but these errors were encountered: