Ask HN: What do you use to test Frontend code? 15 years ago
You could try with Jasmine, although it's not for this specific purpose...
And I agree with simplegeek, selenium should be fine in your case. Although can't imagine how you could test animations... :)