diff options
author | Richard Worth <rdworth@gmail.com> | 2009-02-02 07:14:19 +0000 |
---|---|---|
committer | Richard Worth <rdworth@gmail.com> | 2009-02-02 07:14:19 +0000 |
commit | 977c6e955d8ba1ea7bc1107e739c2cf7d7cf842a (patch) | |
tree | 20bc9e25f4e70d3748edc9915b6cc7b7d32df7be | |
parent | 60b7c7e0f1eea663cd264e0de75a50c645b89c11 (diff) | |
download | jquery-ui-977c6e955d8ba1ea7bc1107e739c2cf7d7cf842a.tar.gz jquery-ui-977c6e955d8ba1ea7bc1107e739c2cf7d7cf842a.zip |
Failing test for #4037 (droppable: cssNamespace option should be removed, addClasses option added)
-rw-r--r-- | tests/unit/droppable/droppable_defaults.js | 2 | ||||
-rw-r--r-- | tests/unit/droppable/droppable_options.js | 12 |
2 files changed, 13 insertions, 1 deletions
diff --git a/tests/unit/droppable/droppable_defaults.js b/tests/unit/droppable/droppable_defaults.js index 0c25bb686..1c175631b 100644 --- a/tests/unit/droppable/droppable_defaults.js +++ b/tests/unit/droppable/droppable_defaults.js @@ -3,9 +3,9 @@ */ var droppable_defaults = { + addClasses: true, accept: '*', activeClass: false, - cssNamespace: "ui", disabled: false, greedy: false, hoverClass: false, diff --git a/tests/unit/droppable/droppable_options.js b/tests/unit/droppable/droppable_options.js index a6b5bbe75..2df2dcb15 100644 --- a/tests/unit/droppable/droppable_options.js +++ b/tests/unit/droppable/droppable_options.js @@ -17,6 +17,18 @@ test("activeClass", function() { ok(false, 'missing test - untested code is broken code'); }); +test("{ addClasses: true }, default", function() { + equals(droppable_defaults.addClasses, true); + + el = $("<div></div>").droppable({ addClasses: true }); + ok(el.is(".ui-droppable"), "'ui-droppable' class added"); +}); + +test("{ addClasses: false }", function() { + el = $("<div></div>").droppable({ addClasses: false }); + ok(!el.is(".ui-droppable"), "'ui-droppable' class not added"); +}); + test("cssNamespace", function() { //cssNamespace should be appended with '-droppable' and added as className el = $("<div></div>").droppable({ cssNamespace: "ui" }); |