diff options
author | Felix Nagel <info@felixnagel.com> | 2013-05-30 21:21:44 +0200 |
---|---|---|
committer | Felix Nagel <info@felixnagel.com> | 2013-05-30 21:21:44 +0200 |
commit | e7d200f308f477a39dc4dfce5ee693143fb5602f (patch) | |
tree | ea6554775fa3dac0e407dd03378e19917c37c31b /tests/unit/selectmenu/selectmenu_events.js | |
parent | 84ee9d86459215af856c9d73fde382fee7cbb874 (diff) | |
download | jquery-ui-e7d200f308f477a39dc4dfce5ee693143fb5602f.tar.gz jquery-ui-e7d200f308f477a39dc4dfce5ee693143fb5602f.zip |
Selectmenu tests: test if close event is fired when selectmenu is closed by click on body
Diffstat (limited to 'tests/unit/selectmenu/selectmenu_events.js')
-rw-r--r-- | tests/unit/selectmenu/selectmenu_events.js | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/unit/selectmenu/selectmenu_events.js b/tests/unit/selectmenu/selectmenu_events.js index f1622adb9..4d98c9dde 100644 --- a/tests/unit/selectmenu/selectmenu_events.js +++ b/tests/unit/selectmenu/selectmenu_events.js @@ -32,7 +32,7 @@ test( "change", function () { test( "close", function () { - expect( 2 ); + expect( 4 ); this.element.selectmenu({ close: function ( event, ui ) { @@ -40,8 +40,11 @@ test( "close", function () { equal( event.type, "selectmenuclose", "event type set to selectmenuclose" ); } }); - + this.element.selectmenu( "open" ).selectmenu( "close" ); + + this.element.selectmenu( "open" ); + $( "body" ).simulate( "click" ); }); |