aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCorey Frang <gnarf@gnarf.net>2012-05-11 15:32:50 -0500
committerCorey Frang <gnarf@gnarf.net>2012-05-11 15:32:50 -0500
commit7799f21307c3e7c16c1b99b79b8f9f93f969b440 (patch)
treeb0bfba74119409d9be8801cc3fa3cfbe7400a2a4
parentafb34fe227d158b3a0bf1a9ac350b6c4da718d80 (diff)
downloadjquery-7799f21307c3e7c16c1b99b79b8f9f93f969b440.tar.gz
jquery-7799f21307c3e7c16c1b99b79b8f9f93f969b440.zip
Fixes #8892: Adding unit test for #8892 - Actually fixed in 58ed62e
-rw-r--r--test/unit/effects.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/unit/effects.js b/test/unit/effects.js
index 0fab3f5f2..59a3d3627 100644
--- a/test/unit/effects.js
+++ b/test/unit/effects.js
@@ -1495,3 +1495,17 @@ asyncTest( "Animate callbacks have correct context", 2, function() {
start();
});
});
+
+asyncTest( "User supplied callback called after show when fx off (#8892)", 2, function() {
+ var foo = jQuery( "#foo" );
+ jQuery.fx.off = true;
+ foo.hide();
+ foo.fadeIn( 500, function() {
+ ok( jQuery( this ).is( ":visible" ), "Element is visible in callback" );
+ foo.fadeOut( 500, function() {
+ ok( jQuery( this ).is( ":hidden" ), "Element is hidden in callback" );
+ jQuery.fx.off = false;
+ start();
+ });
+ });
+});