aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2011-08-03 16:12:46 -0400
committerScott González <scott.gonzalez@gmail.com>2011-08-03 16:13:03 -0400
commit6867e0b5517d4664e309652f807011ea350d1f67 (patch)
treefb9617dfee63ba0fddbc30dbb380300669fbcc0a
parentd912c30e22af920db56af51ab48f4cc307a59ce3 (diff)
downloadjquery-ui-6867e0b5517d4664e309652f807011ea350d1f67.tar.gz
jquery-ui-6867e0b5517d4664e309652f807011ea350d1f67.zip
Autocomplete tests: Fixed handling of cached ajax requests in IE.
-rw-r--r--tests/unit/autocomplete/autocomplete_options.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/unit/autocomplete/autocomplete_options.js b/tests/unit/autocomplete/autocomplete_options.js
index 01c4e9fef..8d11aa399 100644
--- a/tests/unit/autocomplete/autocomplete_options.js
+++ b/tests/unit/autocomplete/autocomplete_options.js
@@ -117,7 +117,6 @@ function sourceTest( source, async ) {
source: source
}),
menu = element.autocomplete( "widget" );
- element.val( "ja" ).autocomplete( "search" );
function result() {
equal( menu.find( ".ui-menu-item" ).text(), "javajavascript" );
element.autocomplete( "destroy" );
@@ -128,7 +127,9 @@ function sourceTest( source, async ) {
if ( async ) {
stop();
$( document ).one( "ajaxStop", result );
- } else {
+ }
+ element.val( "ja" ).autocomplete( "search" );
+ if ( !async ) {
result();
}
}