Add the error handle if we don't support animation-duration:auto.
In this testcase, view-timeline-range-update-reversed-animation.html, it
assumes there is an animation there. However, Gecko doesn't support
animation-duration:auto
(which is defined in CSS Animations 2), so
getAnimations() may not return the animation (which uses the initial
animation-duration value, 0s, instead).
We have to add this error handle to avoid the js error which causes timeout.
Differential Revision: https://phabricator.services.mozilla.com/D217483
bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1909454
gecko-commit: 9d49d3b850c6ceac935f953f2aa6713c08b25ac4
gecko-reviewers: layout-reviewers, emilio