diff options
author | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-03-07 19:54:06 +0100 |
---|---|---|
committer | Jörn Zaefferer <joern.zaefferer@gmail.com> | 2012-03-07 19:54:06 +0100 |
commit | c7cf13f5ed42823fc52eae6f6376438af8467a00 (patch) | |
tree | fc220a13d4557aa1f4ecbdfa422a20e1fb12517a /tests/unit | |
parent | 724772e591e9e721b33c7e2739649b9c5d7a4246 (diff) | |
download | jquery-ui-c7cf13f5ed42823fc52eae6f6376438af8467a00.tar.gz jquery-ui-c7cf13f5ed42823fc52eae6f6376438af8467a00.zip |
Accordion: Update method tests - active option still works when accordion is disabled
Diffstat (limited to 'tests/unit')
-rw-r--r-- | tests/unit/accordion/accordion_methods.js | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/tests/unit/accordion/accordion_methods.js b/tests/unit/accordion/accordion_methods.js index 9f61647c4..2f4722070 100644 --- a/tests/unit/accordion/accordion_methods.js +++ b/tests/unit/accordion/accordion_methods.js @@ -10,15 +10,19 @@ test( "destroy", function() { }); test( "enable/disable", function() { - expect( 3 ); + expect( 4 ); var element = $( "#list1" ).accordion(); accordion_state( element, 1, 0, 0 ); element.accordion( "disable" ); - element.accordion( "option", "active", 1 ); + // event does nothing + element.find( ".ui-accordion-header" ).eq( 1 ).trigger( "click" ); accordion_state( element, 1, 0, 0 ); - element.accordion( "enable" ); + // option still works element.accordion( "option", "active", 1 ); accordion_state( element, 0, 1, 0 ); + element.accordion( "enable" ); + element.accordion( "option", "active", 2 ); + accordion_state( element, 0, 0, 1 ); }); test( "refresh", function() { |