aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/droppable
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2013-03-14 15:07:06 -0400
committerScott González <scott.gonzalez@gmail.com>2013-03-14 15:07:06 -0400
commit23771d38ba9d2663f6db0243c8e992dc7ff6844a (patch)
tree6345e5bf4901f23f2d0bf59b7a1d37743db37921 /tests/unit/droppable
parent38fce3f30478bcfce8ea837d850f63b5560d605a (diff)
downloadjquery-ui-23771d38ba9d2663f6db0243c8e992dc7ff6844a.tar.gz
jquery-ui-23771d38ba9d2663f6db0243c8e992dc7ff6844a.zip
Revert "Widget: Stop setting ui-state-disabled and aria by default on setting disabled option." This needs to wait for a major release.
This reverts commit 4d67f4f34908a50ef88f95df4103ee001b777e45.
Diffstat (limited to 'tests/unit/droppable')
-rw-r--r--tests/unit/droppable/droppable_methods.js29
1 files changed, 13 insertions, 16 deletions
diff --git a/tests/unit/droppable/droppable_methods.js b/tests/unit/droppable/droppable_methods.js
index f7682d262..2b452a63d 100644
--- a/tests/unit/droppable/droppable_methods.js
+++ b/tests/unit/droppable/droppable_methods.js
@@ -63,29 +63,26 @@ test("enable", function() {
equal(actual, expected, "enable is chainable");
});
-test( "disable", function() {
- expect( 10 );
+test("disable", function() {
+ expect(7);
- var actual, expected,
- element = $( "#droppable1" ).droppable({ disabled: false });
+ var el, actual, expected;
+ el = $("#droppable1").droppable({ disabled: false });
TestHelpers.droppable.shouldDrop();
- element.droppable( "disable" );
+ el.droppable("disable");
TestHelpers.droppable.shouldNotDrop();
- equal( element.droppable( "option", "disabled" ), true, "disabled option getter" );
- element.droppable( "destroy" );
- element.droppable({ disabled: false });
+ equal(el.droppable("option", "disabled"), true, "disabled option getter");
+ el.droppable("destroy");
+ el.droppable({ disabled: false });
TestHelpers.droppable.shouldDrop();
- element.droppable( "option", "disabled", true );
- ok( !element.droppable( "widget" ).hasClass( "ui-state-disabled" ), "element does not get ui-state-disabled" );
- ok( !element.droppable( "widget" ).attr( "aria-disabled" ), "element does not get aria-disabled" );
- ok( element.droppable( "widget" ).hasClass( "ui-droppable-disabled" ), "element gets ui-droppable-disabled" );
- equal( element.droppable( "option", "disabled" ), true, "disabled option setter" );
+ el.droppable("option", "disabled", true);
+ equal(el.droppable("option", "disabled"), true, "disabled option setter");
TestHelpers.droppable.shouldNotDrop();
- expected = $( "<div></div>" ).droppable();
- actual = expected.droppable( "disable" );
- equal( actual, expected, "disable is chainable" );
+ expected = $("<div></div>").droppable(),
+ actual = expected.droppable("disable");
+ equal(actual, expected, "disable is chainable");
});
})(jQuery);