Add unit test for wheel + buttons pressed
This commit is contained in:
parent
7a4d1a8274
commit
de9d6888db
|
@ -3964,6 +3964,21 @@ describe('Remote Frame Buffer protocol client', function () {
|
|||
expect(pointerEvent.secondCall).to.have.been.calledWith(client._sock,
|
||||
10, 10, 0);
|
||||
});
|
||||
|
||||
it('should handle wheel event with buttons pressed', function () {
|
||||
sendMouseButtonEvent(10, 10, true, 0, client);
|
||||
sendWheelEvent(10, 10, 0, 50);
|
||||
|
||||
expect(pointerEvent).to.have.been.called.calledThrice;
|
||||
|
||||
expect(pointerEvent.firstCall).to.have.been.calledWith(client._sock,
|
||||
10, 10, 0x1);
|
||||
expect(pointerEvent.secondCall).to.have.been.calledWith(client._sock,
|
||||
10, 10, 0x11);
|
||||
expect(pointerEvent.thirdCall).to.have.been.calledWith(client._sock,
|
||||
10, 10, 0x1);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
describe('Keyboard events', function () {
|
||||
|
|
Loading…
Reference in New Issue