mirror of
https://github.com/jquery/jquery.git
synced 2026-01-26 11:08:08 -05:00
Pre-focus the element so the browser won't fire focus while we're faking it.
At this point the unit test is only testing our ability to fake-fire focusin the right way. These machinations are related to the problem in #6705.
This commit is contained in:
@@ -2324,6 +2324,9 @@ test("focusin bubbles", function() {
|
||||
var input = jQuery( "<input type='text' />" ).prependTo( "body" ),
|
||||
order = 0;
|
||||
|
||||
// focus the element so DOM focus won't fire
|
||||
input[0].focus();
|
||||
|
||||
jQuery( "body" ).bind( "focusin.focusinBubblesTest", function(){
|
||||
equal( 1, order++, "focusin on the body second" );
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user