diff --git a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeCompletableObserverTest.java b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeCompletableObserverTest.java index 9be043b17..987b4c10f 100755 --- a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeCompletableObserverTest.java +++ b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeCompletableObserverTest.java @@ -53,9 +53,6 @@ public class AutoDisposeCompletableObserverTest { } }; - private final AtomicReference atomicObserver = new AtomicReference<>(); - private final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); - @After public void resetPlugins() { AutoDisposePlugins.reset(); } @@ -289,6 +286,8 @@ public class AutoDisposeCompletableObserverTest { } @Test public void verifyObserverDelegate() { + final AtomicReference atomicObserver = new AtomicReference<>(); + final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); try { RxJavaPlugins.setOnCompletableSubscribe(new BiFunction() { @Override public CompletableObserver apply(Completable source, CompletableObserver observer) { diff --git a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeMaybeObserverTest.java b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeMaybeObserverTest.java index 9751941fd..f66799f35 100755 --- a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeMaybeObserverTest.java +++ b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeMaybeObserverTest.java @@ -52,10 +52,6 @@ public class AutoDisposeMaybeObserverTest { } }; - private final AtomicReference atomicObserver = new AtomicReference<>(); - private final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); - - @After public void resetPlugins() { AutoDisposePlugins.reset(); } @@ -336,6 +332,8 @@ public class AutoDisposeMaybeObserverTest { } @Test public void verifyObserverDelegate() { + final AtomicReference atomicObserver = new AtomicReference<>(); + final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); try { RxJavaPlugins.setOnMaybeSubscribe(new BiFunction() { @Override public MaybeObserver apply(Maybe source, MaybeObserver observer) { diff --git a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeObserverTest.java b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeObserverTest.java index b19b7dd79..a275d8d66 100755 --- a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeObserverTest.java +++ b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeObserverTest.java @@ -48,9 +48,6 @@ public class AutoDisposeObserverTest { } }; - private final AtomicReference atomicObserver = new AtomicReference(); - private final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); - @After public void resetPlugins() { AutoDisposePlugins.reset(); } @@ -265,6 +262,8 @@ public class AutoDisposeObserverTest { } @Test public void verifyObserverDelegate() { + final AtomicReference atomicObserver = new AtomicReference(); + final AtomicReference atomicAutoDisposingObserver = new AtomicReference(); try { RxJavaPlugins.setOnObservableSubscribe(new BiFunction() { @Override public Observer apply(Observable source, Observer observer) { diff --git a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSingleObserverTest.java b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSingleObserverTest.java index 6236000ad..1a7b3b18d 100755 --- a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSingleObserverTest.java +++ b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSingleObserverTest.java @@ -18,7 +18,6 @@ import com.uber.autodispose.test.RecordingObserver; import com.uber.autodispose.observers.AutoDisposingSingleObserver; - import io.reactivex.Maybe; import io.reactivex.Single; import io.reactivex.SingleEmitter; @@ -51,9 +50,6 @@ public class AutoDisposeSingleObserverTest { } }; - private final AtomicReference atomicObserver = new AtomicReference<>(); - private final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); - @After public void resetPlugins() { AutoDisposePlugins.reset(); } @@ -303,6 +299,8 @@ public class AutoDisposeSingleObserverTest { } @Test public void verifyObserverDelegate() { + final AtomicReference atomicObserver = new AtomicReference<>(); + final AtomicReference atomicAutoDisposingObserver = new AtomicReference<>(); try { RxJavaPlugins.setOnSingleSubscribe(new BiFunction() { @Override public SingleObserver apply(Single source, SingleObserver observer) { diff --git a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSubscriberTest.java b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSubscriberTest.java index f804aac70..f166ee48d 100755 --- a/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSubscriberTest.java +++ b/autodispose/src/test/java/com/uber/autodispose/AutoDisposeSubscriberTest.java @@ -48,9 +48,6 @@ public class AutoDisposeSubscriberTest { - private final AtomicReference atomicSubscriber = new AtomicReference<>(); - private final AtomicReference atomicAutoDisposingSubscriber = new AtomicReference<>(); - @After public void resetPlugins() { AutoDisposePlugins.reset(); } @@ -277,6 +274,8 @@ public class AutoDisposeSubscriberTest { } @Test public void verifySubscriberDelegate() { + final AtomicReference atomicSubscriber = new AtomicReference<>(); + final AtomicReference atomicAutoDisposingSubscriber = new AtomicReference<>(); try { RxJavaPlugins.setOnFlowableSubscribe(new BiFunction() { @Override public Subscriber apply(Flowable source, Subscriber subscriber) {