diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/unit/autocomplete/autocomplete_events.js | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/unit/autocomplete/autocomplete_events.js b/tests/unit/autocomplete/autocomplete_events.js index 286d902f1..d6a008ea2 100644 --- a/tests/unit/autocomplete/autocomplete_events.js +++ b/tests/unit/autocomplete/autocomplete_events.js @@ -157,6 +157,25 @@ asyncTest( "cancel select", function() { }, 50 ); }); +asyncTest( "blur during remote search", function() { + expect( 1 ); + var ac = $( "#autocomplete" ).autocomplete({ + delay: 0, + source: function( request, response ) { + ok( true, "trigger request" ); + ac.simulate( "blur" ); + setTimeout(function() { + response([ "result" ]); + start(); + }, 100 ); + }, + open: function() { + ok( false, "opened after a blur" ); + } + }); + ac.val( "ro" ).keydown(); +}); + /* TODO previous fix broke more than it fixed, disabling this for now - messed up regular menu select event test("blur without selection", function() { expect(1); |