Commit 66c98419 authored by John Resig's avatar John Resig

Retool the fx test again, making it more apparent which order the queue tests will complete in.

parent db822622
...@@ -53,20 +53,16 @@ test("animate option (queue === false)", function () { ...@@ -53,20 +53,16 @@ test("animate option (queue === false)", function () {
var order = []; var order = [];
var $foo = jQuery("#foo"); var $foo = jQuery("#foo");
$foo.animate({width:'100px'}, 200, function () { $foo.animate({width:'100px'}, 3000, function () {
// should finish after unqueued animation so second // should finish after unqueued animation so second
order.push(2); order.push(2);
isSet( order, [ 1, 2 ], "Animations finished in the correct order" );
start();
}); });
$foo.animate({fontSize:'2em'}, {queue:false, duration:10, complete:function () { $foo.animate({fontSize:'2em'}, {queue:false, duration:10, complete:function () {
// short duration and out of queue so should finish first // short duration and out of queue so should finish first
order.push(1); order.push(1);
}}); }});
$foo.animate({height:'100px'}, 100, function() {
// queued behind the first animation so should finish third
order.push(3);
isSet( order, [ 1, 2, 3], "Animations finished in the correct order" );
start();
});
}); });
test("animate duration 0", function() { test("animate duration 0", function() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment