mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-11-21 11:04:24 +00:00
Dialog: Added tests for isOpen method.
This commit is contained in:
parent
2675acc088
commit
4705f5cc2e
@ -23,7 +23,7 @@ var defaults = {
|
||||
position: 'center',
|
||||
resizable: true,
|
||||
stack: true,
|
||||
title: null,
|
||||
title: '',
|
||||
width: 300
|
||||
};
|
||||
|
||||
@ -396,6 +396,21 @@ test("width", function() {
|
||||
|
||||
module("dialog: Methods");
|
||||
|
||||
test("isOpen", function() {
|
||||
expect(4);
|
||||
el = $('<div/>').dialog();
|
||||
equals(el.dialog('isOpen'), true, "dialog is open after init");
|
||||
el.dialog('close');
|
||||
equals(el.dialog('isOpen'), false, "dialog is closed");
|
||||
el.remove();
|
||||
|
||||
el = $('<div/>').dialog({autoOpen: false});
|
||||
equals(el.dialog('isOpen'), false, "dialog is closed after init");
|
||||
el.dialog('open');
|
||||
equals(el.dialog('isOpen'), true, "dialog is open");
|
||||
el.remove();
|
||||
});
|
||||
|
||||
module("dialog: Callbacks");
|
||||
|
||||
test("open", function() {
|
||||
|
Loading…
Reference in New Issue
Block a user