From 88b909b04ec43443514867f83171cbc9760bb638 Mon Sep 17 00:00:00 2001 From: jzaefferer Date: Wed, 31 Mar 2010 16:39:16 +0200 Subject: [PATCH] Autocomplete unit tests: Replace unreliable setTimeout with gobal ajax event handler --- tests/unit/autocomplete/autocomplete_options.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/unit/autocomplete/autocomplete_options.js b/tests/unit/autocomplete/autocomplete_options.js index 6639e9014..c5aa7c961 100644 --- a/tests/unit/autocomplete/autocomplete_options.js +++ b/tests/unit/autocomplete/autocomplete_options.js @@ -120,7 +120,7 @@ function source_test(source, async) { } if (async) { stop(); - setTimeout(result, 100); + $(document).one("ajaxStop", result); } else { result(); }