diff options
Diffstat (limited to 'tests/unit/draggable/draggable_test_helpers.js')
-rw-r--r-- | tests/unit/draggable/draggable_test_helpers.js | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/unit/draggable/draggable_test_helpers.js b/tests/unit/draggable/draggable_test_helpers.js index c17992b98..285da1447 100644 --- a/tests/unit/draggable/draggable_test_helpers.js +++ b/tests/unit/draggable/draggable_test_helpers.js @@ -25,11 +25,13 @@ TestHelpers.draggable = { msg = msg ? msg + "." : ""; deepEqual( actual, expected, "dragged[" + dx + ", " + dy + "] " + msg ); }, - shouldMove: function( el, why ) { - TestHelpers.draggable.testDrag( el, el, 50, 50, 50, 50, why ); + shouldMove: function( el, why, handle ) { + handle = handle || el; + TestHelpers.draggable.testDrag( el, handle, 50, 50, 50, 50, why ); }, - shouldNotMove: function( el, why ) { - TestHelpers.draggable.testDrag( el, el, 50, 50, 0, 0, why ); + shouldNotMove: function( el, why, handle ) { + handle = handle || el; + TestHelpers.draggable.testDrag( el, handle, 50, 50, 0, 0, why ); }, testScroll: function( el, position ) { var oldPosition = $( "#main" ).css( "position" ); |