diff options
author | Trisha Crowley <trisha.crowley@gmail.com> | 2014-10-06 22:26:29 -0400 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2014-10-07 07:45:01 -0400 |
commit | c48b18b388b566b4f6a4d833775db70eb62f4f29 (patch) | |
tree | 747c577fd3023f30ea057e75471291b0c09ec4bc /tests/unit/menu/menu_events.js | |
parent | 29c72fc256be3294d5dc2e0e21a69e13acb29b3a (diff) | |
download | jquery-ui-c48b18b388b566b4f6a4d833775db70eb62f4f29.tar.gz jquery-ui-c48b18b388b566b4f6a4d833775db70eb62f4f29.zip |
Menu: Typeahead now accounts for leading whitespace
Fixes #10649
Closes gh-1356
Diffstat (limited to 'tests/unit/menu/menu_events.js')
-rw-r--r-- | tests/unit/menu/menu_events.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/unit/menu/menu_events.js b/tests/unit/menu/menu_events.js index ff7eb4c7c..02e63bf63 100644 --- a/tests/unit/menu/menu_events.js +++ b/tests/unit/menu/menu_events.js @@ -609,7 +609,7 @@ asyncTest( "handle keyboard navigation and mouse click on menu with dividers and }); asyncTest( "handle keyboard navigation with spelling of menu items", function() { - expect( 2 ); + expect( 3 ); var element = $( "#menu2" ).menu({ focus: function( event ) { log( $( event.target ).find( ".ui-state-focus" ).index() ); @@ -624,6 +624,8 @@ asyncTest( "handle keyboard navigation with spelling of menu items", function() equal( logOutput(), "keydown,0,1,3", "Keydown focus Addyston by spelling the first 3 letters" ); element.simulate( "keydown", { keyCode: 68 } ); equal( logOutput(), "keydown,0,1,3,4", "Keydown focus Delphi by repeating the 'd' again" ); + element.simulate( "keydown", { keyCode: 83 } ); + equal( logOutput(), "keydown,0,1,3,4,5", "Keydown focus Saarland ignoring leading space" ); start(); }); element[ 0 ].focus(); |