diff --git a/tests/unit/autocomplete/autocomplete_options.js b/tests/unit/autocomplete/autocomplete_options.js index 8d11aa399..114e9a42b 100644 --- a/tests/unit/autocomplete/autocomplete_options.js +++ b/tests/unit/autocomplete/autocomplete_options.js @@ -34,7 +34,7 @@ function autoFocusTest( afValue, focusedLength ) { delay: 0, source: data, open: function( event, ui ) { - equal( element.autocomplete( "widget" ).children( ".ui-menu-item:first .ui-state-focus" ).length, + equal( element.autocomplete( "widget" ).children( ".ui-menu-item:first" ).find( ".ui-state-focus" ).length, focusedLength, "first item is " + (afValue ? "" : "not") + " auto focused" ); start(); }