package org.robolectric.shadows;

import android.animation.ValueAnimator;
import org.robolectric.annotation.Implements;
import org.robolectric.annotation.RealObject;
import org.robolectric.annotation.Resetter;
import org.robolectric.util.ReflectionHelpers;

@Implements(ValueAnimator.class)
public class ShadowValueAnimator extends ShadowAnimator {

  @Resetter
  public static void reset() {
    ValueAnimator.clearAllAnimations();
  }
}

@@ -67,16 +67,17 @@
 imator;%0A
+%0A
 import o
@@ -118,54 +118,8 @@
 ts;%0A
-import org.robolectric.annotation.RealObject;%0A
 impo
@@ -341,16 +341,16 @@
 set() %7B%0A
-
     Valu
@@ -381,14 +381,780 @@
 ions();%0A
+    /* ValueAnimator.sAnimationHandler is a static thread local that otherwise would survive between%0A     * tests. The AnimationHandler.mAnimationScheduled is set to true when the scheduleAnimation() is%0A     * called and the reset to false when run() is called by the Choreographer. If an animation is%0A     * already scheduled, it will not post to the Choreographer. This is a problem if a previous%0A     * test leaves animations on the Choreographers callback queue without running them as it will%0A     * cause the AnimationHandler not to post a callback. We reset the thread local here so a new%0A     * one will be created for each test with a fresh state.%0A     */%0A    ReflectionHelpers.setStaticField(ValueAnimator.class, %22sAnimationHandler%22, new ThreadLocal%3C%3E());%0A
   %7D%0A%7D%0A

Fix test pollution in ShadowValueAnimator.