diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-03-01 13:35:04 +0100 |
---|---|---|
committer | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-03-01 13:35:04 +0100 |
commit | 6d20d1463b7f5bd858a50247d6424af934c1ccee (patch) | |
tree | 09da127cc2288327bb874ed7367ab3221b42b8e8 /tests/unit/dialog/dialog_methods.js | |
parent | 59f2e88c58f0018f22b1c3be4bb5e9549a944381 (diff) | |
parent | 09732dace8156a10065e29d9cb0e4007fa079d8f (diff) | |
download | jquery-ui-6d20d1463b7f5bd858a50247d6424af934c1ccee.tar.gz jquery-ui-6d20d1463b7f5bd858a50247d6424af934c1ccee.zip |
Merge branch 'master' into data-naming
Diffstat (limited to 'tests/unit/dialog/dialog_methods.js')
-rw-r--r-- | tests/unit/dialog/dialog_methods.js | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/tests/unit/dialog/dialog_methods.js b/tests/unit/dialog/dialog_methods.js index a961b4e03..645baa9f5 100644 --- a/tests/unit/dialog/dialog_methods.js +++ b/tests/unit/dialog/dialog_methods.js @@ -45,36 +45,36 @@ test("destroy", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('destroy'); - equals(actual, expected, 'destroy is chainable'); + equal(actual, expected, 'destroy is chainable'); }); test("enable", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('enable'); - equals(actual, expected, 'enable is chainable'); - + equal(actual, expected, 'enable is chainable'); + el = $('<div></div>').dialog({ disabled: true }); el.dialog('enable'); - equals(el.dialog('option', 'disabled'), false, 'enable method sets disabled option to false'); + equal(el.dialog('option', 'disabled'), false, 'enable method sets disabled option to false'); ok(!dlg().hasClass('ui-dialog-disabled'), 'enable method removes ui-dialog-disabled class from ui-dialog element'); }); test("disable", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('disable'); - equals(actual, expected, 'disable is chainable'); - + equal(actual, expected, 'disable is chainable'); + el = $('<div></div>').dialog({ disabled: false }); el.dialog('disable'); - equals(el.dialog('option', 'disabled'), true, 'disable method sets disabled option to true'); + equal(el.dialog('option', 'disabled'), true, 'disable method sets disabled option to true'); ok(dlg().hasClass('ui-dialog-disabled'), 'disable method adds ui-dialog-disabled class to ui-dialog element'); }); test("close", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('close'); - equals(actual, expected, 'close is chainable'); - + equal(actual, expected, 'close is chainable'); + el = $('<div></div>').dialog(); ok(dlg().is(':visible') && !dlg().is(':hidden'), 'dialog visible before close method called'); el.dialog('close'); @@ -85,22 +85,22 @@ test("isOpen", function() { expect(4); el = $('<div></div>').dialog(); - equals(el.dialog('isOpen'), true, "dialog is open after init"); + equal(el.dialog('isOpen'), true, "dialog is open after init"); el.dialog('close'); - equals(el.dialog('isOpen'), false, "dialog is closed"); + equal(el.dialog('isOpen'), false, "dialog is closed"); el.remove(); el = $('<div></div>').dialog({autoOpen: false}); - equals(el.dialog('isOpen'), false, "dialog is closed after init"); + equal(el.dialog('isOpen'), false, "dialog is closed after init"); el.dialog('open'); - equals(el.dialog('isOpen'), true, "dialog is open"); + equal(el.dialog('isOpen'), true, "dialog is open"); el.remove(); }); test("moveToTop", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('moveToTop'); - equals(actual, expected, 'moveToTop is chainable'); + equal(actual, expected, 'moveToTop is chainable'); var d1 = $('<div></div>').dialog(), dlg1 = d1.parents('.ui-dialog'); d1.dialog('close'); @@ -116,7 +116,7 @@ test("moveToTop", function() { test("open", function() { var expected = $('<div></div>').dialog(), actual = expected.dialog('open'); - equals(actual, expected, 'open is chainable'); + equal(actual, expected, 'open is chainable'); el = $('<div></div>').dialog({ autoOpen: false }); ok(dlg().is(':hidden') && !dlg().is(':visible'), 'dialog hidden before open method called'); |