Fix style recalc assumption in LayoutTests/svg/custom/mask-invalidation.svg

This patch fixes an incorrect assumption in mask-invalidation.svg that
a style recalc occurs after deferring to setTimeout. This patch replaces
that setTimeout with a requestAnimationFrame call.

R=abarth
BUG=337885
NOTRY=true

Review URL: https://codereview.chromium.org/140613006

git-svn-id: svn://svn.chromium.org/blink/trunk@165870 bbb929c8-8fbe-4397-9dbb-9b2b20218538