aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/draggable/draggable_methods.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/unit/draggable/draggable_methods.js')
-rw-r--r--tests/unit/draggable/draggable_methods.js14
1 files changed, 5 insertions, 9 deletions
diff --git a/tests/unit/draggable/draggable_methods.js b/tests/unit/draggable/draggable_methods.js
index 63a19e26d..901c261d6 100644
--- a/tests/unit/draggable/draggable_methods.js
+++ b/tests/unit/draggable/draggable_methods.js
@@ -74,16 +74,16 @@ test( "enable", function() {
});
test( "disable", function() {
- expect( 10 );
+ expect( 7 );
- element = $( "#draggable2" ).draggable({ disabled: false });
+ element = $("#draggable2").draggable({ disabled: false });
TestHelpers.draggable.shouldMove( element, ".draggable({ disabled: false })" );
- element.draggable( "disable" );
+ element.draggable("disable");
TestHelpers.draggable.shouldNotMove( element, ".draggable('disable')" );
equal( element.draggable( "option", "disabled" ), true, "disabled option getter" );
- element.draggable( "destroy" );
+ element.draggable("destroy");
element.draggable({ disabled: false });
TestHelpers.draggable.shouldMove( element, ".draggable({ disabled: false })" );
@@ -91,12 +91,8 @@ test( "disable", function() {
equal( element.draggable( "option", "disabled" ), true, "disabled option setter" );
TestHelpers.draggable.shouldNotMove( element, ".draggable('option', 'disabled', true)" );
- ok( !element.draggable( "widget" ).hasClass( "ui-state-disabled" ), "element does not get ui-state-disabled" );
- ok( !element.draggable( "widget" ).attr( "aria-disabled" ), "element does not get aria-disabled" );
- ok( element.draggable( "widget" ).hasClass( "ui-draggable-disabled" ), "element gets ui-draggable-disabled" );
-
var expected = element.draggable(),
- actual = expected.draggable( "disable" );
+ actual = expected.draggable("disable");
equal( actual, expected, "disable is chainable" );
});