diff options
author | Dave Methvin <dave.methvin@gmail.com> | 2013-01-26 22:02:15 -0500 |
---|---|---|
committer | Dave Methvin <dave.methvin@gmail.com> | 2013-01-26 22:02:15 -0500 |
commit | a6c358d04693c5746e1557a2660dfccb169ad831 (patch) | |
tree | 57a076e4470ea9001fce9dcae2060da8e89a7239 /test/unit | |
parent | b594673a4294a75c10db279239edfa60b6bb804e (diff) | |
download | jquery-a6c358d04693c5746e1557a2660dfccb169ad831.tar.gz jquery-a6c358d04693c5746e1557a2660dfccb169ad831.zip |
Fix #12846. Restore overflow when animation is stopped.
Diffstat (limited to 'test/unit')
-rw-r--r-- | test/unit/effects.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/unit/effects.js b/test/unit/effects.js index 3f986097e..8c56581db 100644 --- a/test/unit/effects.js +++ b/test/unit/effects.js @@ -1758,16 +1758,18 @@ asyncTest("Animation callbacks (#11797)", 15, function() { }); }); -test( "Animate properly sets overflow hidden when animating width/height (#12117)", 4, function() { +test( "Animate properly sets overflow hidden when animating width/height (#12117)", 8, function() { jQuery.each( [ "height", "width" ], function( _, prop ) { jQuery.each( [ 100, 0 ], function( _, value ) { - var div = jQuery("<div>"), + var div = jQuery("<div>").css( "overflow", "auto" ), props = {}; props[ prop ] = value; div.animate( props, 1 ); equal( div.css( "overflow" ), "hidden", "overflow: hidden set when animating " + prop + " to " + value ); div.stop(); + equal( div.css( "overflow" ), "auto", + "overflow: auto restored after animating " + prop + " to " + value ); }); }); }); |