diff options
Diffstat (limited to 'tests/unit/dialog/dialog_methods.js')
-rw-r--r-- | tests/unit/dialog/dialog_methods.js | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/tests/unit/dialog/dialog_methods.js b/tests/unit/dialog/dialog_methods.js index dcb2409d4..93d1b25db 100644 --- a/tests/unit/dialog/dialog_methods.js +++ b/tests/unit/dialog/dialog_methods.js @@ -28,17 +28,15 @@ test("init", function() { ok(true, 'arbitrary method called after init'); el = $('<div></div>').dialog(); - var foo = el.data("foo.dialog"); + var foo = el.dialog("option", "foo"); el.remove(); ok(true, 'arbitrary option getter after init'); - $('<div></div>').dialog().data("foo.dialog", "bar").remove(); + $('<div></div>').dialog().dialog("option", "foo", "bar").remove(); ok(true, 'arbitrary option setter after init'); }); test("destroy", function() { - expect(7); - $("<div></div>").appendTo('body').dialog().dialog("destroy").remove(); ok(true, '.dialog("destroy") called on element'); @@ -51,14 +49,6 @@ test("destroy", function() { $('<div></div>').dialog().dialog("destroy").dialog("foo").remove(); ok(true, 'arbitrary method called after destroy'); - el = $('<div></div>').dialog(); - var foo = el.dialog("destroy").data("foo.dialog"); - el.remove(); - ok(true, 'arbitrary option getter after destroy'); - - $('<div></div>').dialog().dialog("destroy").data("foo.dialog", "bar").remove(); - ok(true, 'arbitrary option setter after destroy'); - var expected = $('<div></div>').dialog(), actual = expected.dialog('destroy'); equals(actual, expected, 'destroy is chainable'); |