diff options
author | Mike Sherov <mike.sherov@gmail.com> | 2012-11-03 16:17:16 -0400 |
---|---|---|
committer | Mike Sherov <mike.sherov@gmail.com> | 2012-11-03 16:17:16 -0400 |
commit | 3df9ea29e644a3dd6345161513dae5823d9b0460 (patch) | |
tree | 08bdc053f90d110cb4af39c4de464d92ad8142c6 /tests/unit/draggable/draggable_events.js | |
parent | 68ad80c2922daccba773a9adafe9fb5efcb129a2 (diff) | |
download | jquery-ui-3df9ea29e644a3dd6345161513dae5823d9b0460.tar.gz jquery-ui-3df9ea29e644a3dd6345161513dae5823d9b0460.zip |
Dev: remove globals from tests and moved test helpers to correct location - Fixed #8770 Dev: Remove globals and Standardize Test Suite
Diffstat (limited to 'tests/unit/draggable/draggable_events.js')
-rw-r--r-- | tests/unit/draggable/draggable_events.js | 44 |
1 files changed, 25 insertions, 19 deletions
diff --git a/tests/unit/draggable/draggable_events.js b/tests/unit/draggable/draggable_events.js index 65e8097a7..6b1136cb0 100644 --- a/tests/unit/draggable/draggable_events.js +++ b/tests/unit/draggable/draggable_events.js @@ -9,12 +9,14 @@ test("callbacks occurrence count", function() { expect(3); - var start = 0, stop = 0, dragc = 0; - el = $("#draggable2").draggable({ - start: function() { start++; }, - drag: function() { dragc++; }, - stop: function() { stop++; } - }); + var start = 0, + stop = 0, + dragc = 0, + el = $("#draggable2").draggable({ + start: function() { start++; }, + drag: function() { dragc++; }, + stop: function() { stop++; } + }); TestHelpers.draggable.drag(el, 10, 10); @@ -28,12 +30,14 @@ test("stopping the start callback", function() { expect(3); - var start = 0, stop = 0, dragc = 0; - el = $("#draggable2").draggable({ - start: function() { start++; return false; }, - drag: function() { dragc++; }, - stop: function() { stop++; } - }); + var start = 0, + stop = 0, + dragc = 0, + el = $("#draggable2").draggable({ + start: function() { start++; return false; }, + drag: function() { dragc++; }, + stop: function() { stop++; } + }); TestHelpers.draggable.drag(el, 10, 10); @@ -47,12 +51,14 @@ test("stopping the drag callback", function() { expect(3); - var start = 0, stop = 0, dragc = 0; - el = $("#draggable2").draggable({ - start: function() { start++;}, - drag: function() { dragc++; return false; }, - stop: function() { stop++; } - }); + var start = 0, + stop = 0, + dragc = 0, + el = $("#draggable2").draggable({ + start: function() { start++;}, + drag: function() { dragc++; return false; }, + stop: function() { stop++; } + }); TestHelpers.draggable.drag(el, 10, 10); @@ -66,7 +72,7 @@ test("stopping the stop callback", function() { expect(1); - el = $("#draggable2").draggable({ + var el = $("#draggable2").draggable({ helper: 'clone', stop: function() { return false; } }); |