[Code health] Move CreateAnimationAndPaintWorkletThread to a test_common.cc

The worklet_thread_test_common.h has this function for AnimationWorklet
already. This CL moves the PaintWorklet version into the same file.

This CL should not change any behavior.

Bug: None
Change-Id: I0dc62af5cc6cc6c35e09cb67dc23eef520ba3d91
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1515132
Commit-Queue: Xida Chen <xidachen@chromium.org>
Reviewed-by: Yi Gu <yigu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#639732}
3 files changed