diff options
Diffstat (limited to 'tests/unit/draggable')
-rw-r--r-- | tests/unit/draggable/core.js | 5 | ||||
-rw-r--r-- | tests/unit/draggable/events.js | 4 | ||||
-rw-r--r-- | tests/unit/draggable/methods.js | 4 | ||||
-rw-r--r-- | tests/unit/draggable/options.js | 8 |
4 files changed, 15 insertions, 6 deletions
diff --git a/tests/unit/draggable/core.js b/tests/unit/draggable/core.js index 1dd6f572a..b5dec8104 100644 --- a/tests/unit/draggable/core.js +++ b/tests/unit/draggable/core.js @@ -1,13 +1,14 @@ define( [ "qunit", "jquery", + "lib/helper", "./helper", "ui/widgets/draggable", "ui/widgets/droppable", "ui/widgets/resizable" -], function( QUnit, $, testHelper ) { +], function( QUnit, $, helper, testHelper ) { -QUnit.module( "draggable: core" ); +QUnit.module( "draggable: core", { afterEach: helper.moduleAfterEach } ); QUnit.test( "element types", function( assert ) { var typeNames = ( diff --git a/tests/unit/draggable/events.js b/tests/unit/draggable/events.js index f8c4a6551..c25754923 100644 --- a/tests/unit/draggable/events.js +++ b/tests/unit/draggable/events.js @@ -1,8 +1,9 @@ define( [ "qunit", "jquery", + "lib/helper", "ui/widgets/draggable" -], function( QUnit, $ ) { +], function( QUnit, $, helper ) { var element; @@ -12,6 +13,7 @@ QUnit.module( "draggable: events", { }, afterEach: function() { element.draggable( "destroy" ); + return helper.moduleAfterEach.apply( this, arguments ); } } ); diff --git a/tests/unit/draggable/methods.js b/tests/unit/draggable/methods.js index 8e95dac30..19c7424a0 100644 --- a/tests/unit/draggable/methods.js +++ b/tests/unit/draggable/methods.js @@ -1,9 +1,10 @@ define( [ "qunit", "jquery", + "lib/helper", "./helper", "ui/widgets/draggable" -], function( QUnit, $, testHelper ) { +], function( QUnit, $, helper, testHelper ) { var element; @@ -13,6 +14,7 @@ QUnit.module( "draggable: methods", { }, afterEach: function() { element.remove(); + return helper.moduleAfterEach.apply( this, arguments ); } } ); diff --git a/tests/unit/draggable/options.js b/tests/unit/draggable/options.js index ff72f9d02..32963b3f6 100644 --- a/tests/unit/draggable/options.js +++ b/tests/unit/draggable/options.js @@ -1,13 +1,14 @@ define( [ "qunit", "jquery", + "lib/helper", "./helper", "ui/widgets/draggable", "ui/widgets/droppable", "ui/widgets/sortable" -], function( QUnit, $, testHelper ) { +], function( QUnit, $, helper, testHelper ) { -QUnit.module( "draggable: options" ); +QUnit.module( "draggable: options", { afterEach: helper.moduleAfterEach } ); // TODO: This doesn't actually test whether append happened, possibly remove QUnit.test( "{ appendTo: 'parent' }, default, no clone", function( assert ) { @@ -301,6 +302,9 @@ QUnit.test( "connectToSortable, dragging out of a sortable", function( assert ) dx: dx, dy: dy } ); + + // Cleanup + element.stop( true ); } ); QUnit.test( "connectToSortable, dragging clone into sortable", function( assert ) { |