@@ -47,32 +47,12 @@ test("destroy", function() {
47
47
} ) ;
48
48
} ) ;
49
49
50
- test ( "enable" , function ( ) {
51
- expect ( 3 ) ;
52
-
53
- var el ,
54
- expected = $ ( '<div></div>' ) . dialog ( ) ,
55
- actual = expected . dialog ( 'enable' ) ;
56
- equal ( actual , expected , 'enable is chainable' ) ;
57
-
58
- el = $ ( '<div></div>' ) . dialog ( { disabled : true } ) ;
59
- el . dialog ( 'enable' ) ;
60
- equal ( el . dialog ( 'option' , 'disabled' ) , false , 'enable method sets disabled option to false' ) ;
61
- ok ( ! el . dialog ( 'widget' ) . hasClass ( 'ui-dialog-disabled' ) , 'enable method removes ui-dialog-disabled class from ui-dialog element' ) ;
62
- } ) ;
63
-
64
- test ( "disable" , function ( ) {
65
- expect ( 3 ) ;
66
-
67
- var el ,
68
- expected = $ ( '<div></div>' ) . dialog ( ) ,
69
- actual = expected . dialog ( 'disable' ) ;
70
- equal ( actual , expected , 'disable is chainable' ) ;
71
-
72
- el = $ ( '<div></div>' ) . dialog ( { disabled : false } ) ;
73
- el . dialog ( 'disable' ) ;
74
- equal ( el . dialog ( 'option' , 'disabled' ) , true , 'disable method sets disabled option to true' ) ;
75
- ok ( el . dialog ( 'widget' ) . hasClass ( 'ui-dialog-disabled' ) , 'disable method adds ui-dialog-disabled class to ui-dialog element' ) ;
50
+ test ( "enable/disable disabled" , function ( ) {
51
+ expect ( 2 ) ;
52
+ var el = $ ( "<div></div>" ) . dialog ( ) ;
53
+ el . dialog ( "disable" ) ;
54
+ equal ( el . dialog ( "option" , "disabled" ) , false , "disable method doesn't do anything" ) ;
55
+ ok ( ! el . dialog ( "widget" ) . hasClass ( "ui-dialog-disabled" ) , "disable method doesn't add ui-dialog-disabled class" ) ;
76
56
} ) ;
77
57
78
58
test ( "close" , function ( ) {
0 commit comments