aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/resizable/resizable_methods.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2009-04-15 02:33:28 +0000
committerScott González <scott.gonzalez@gmail.com>2009-04-15 02:33:28 +0000
commit1195854aaad61308e7f5339eed54f92284d7666e (patch)
tree5991992a73f910d897967559332a15bd774816d8 /tests/unit/resizable/resizable_methods.js
parent3c7b61299333d1ec3f4d4d773b1ec4296129a98e (diff)
downloadjquery-ui-1195854aaad61308e7f5339eed54f92284d7666e.tar.gz
jquery-ui-1195854aaad61308e7f5339eed54f92284d7666e.zip
Merged in widget-factory branch and added tests. Fixes #4411 - Widget factory should auto detect getters.
Diffstat (limited to 'tests/unit/resizable/resizable_methods.js')
-rw-r--r--tests/unit/resizable/resizable_methods.js12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/unit/resizable/resizable_methods.js b/tests/unit/resizable/resizable_methods.js
index 43d573387..e029e00cf 100644
--- a/tests/unit/resizable/resizable_methods.js
+++ b/tests/unit/resizable/resizable_methods.js
@@ -30,7 +30,7 @@ test("init", function() {
});
test("destroy", function() {
- expect(6);
+ expect(7);
$("<div></div>").appendTo('body').resizable().resizable("destroy").remove();
ok(true, '.resizable("destroy") called on element');
@@ -51,13 +51,23 @@ test("destroy", function() {
$('<div></div>').resizable().resizable("destroy").data("foo.resizable", "bar").remove();
ok(true, 'arbitrary option setter after destroy');
+
+ var expected = $('<div></div>').resizable(),
+ actual = expected.resizable('destroy');
+ equals(actual, expected, 'destroy is chainable');
});
test("enable", function() {
+ var expected = $('<div></div>').resizable(),
+ actual = expected.resizable('enable');
+ equals(actual, expected, 'enable is chainable');
ok(false, "missing test - untested code is broken code.");
});
test("disable", function() {
+ var expected = $('<div></div>').resizable(),
+ actual = expected.resizable('disable');
+ equals(actual, expected, 'disable is chainable');
ok(false, "missing test - untested code is broken code.");
});