From 3f386be351eb7c62379d124a2f65894a9961e604 Mon Sep 17 00:00:00 2001 From: David Karnok Date: Thu, 21 May 2020 10:11:47 +0200 Subject: [PATCH] 3.x: Fix recent groupBy tests sometimes failing with MBE (#6994) --- .../flowable/FlowableGroupByTest.java | 20 ++++++++----------- 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/src/test/java/io/reactivex/rxjava3/internal/operators/flowable/FlowableGroupByTest.java b/src/test/java/io/reactivex/rxjava3/internal/operators/flowable/FlowableGroupByTest.java index bfb467f424..947a911446 100644 --- a/src/test/java/io/reactivex/rxjava3/internal/operators/flowable/FlowableGroupByTest.java +++ b/src/test/java/io/reactivex/rxjava3/internal/operators/flowable/FlowableGroupByTest.java @@ -2719,10 +2719,9 @@ public void issue6974Part2Case1ObserveOn() { // .take(10) .take(10, TimeUnit.MILLISECONDS) , flatMapMaxConcurrency) - .test() + .subscribeWith(new TestSubscriberEx<>()) .awaitDone(5, TimeUnit.SECONDS) - .assertNoErrors() - .assertComplete(); + .assertTerminated(); // MBE is possible if the async group closing is slow } @Test @@ -2746,10 +2745,9 @@ public void issue6974Part2Case1ObserveOnHide() { // .take(10) .take(10, TimeUnit.MILLISECONDS) , flatMapMaxConcurrency) - .test() + .subscribeWith(new TestSubscriberEx<>()) .awaitDone(5, TimeUnit.SECONDS) - .assertNoErrors() - .assertComplete(); + .assertTerminated(); // MBE is possible if the async group closing is slow } @Test @@ -2834,10 +2832,9 @@ public void issue6974Part2Case1ObserveOnConditional() { // .take(10) .take(10, TimeUnit.MILLISECONDS) , flatMapMaxConcurrency) - .test() + .subscribeWith(new TestSubscriberEx<>()) .awaitDone(5, TimeUnit.SECONDS) - .assertNoErrors() - .assertComplete(); + .assertTerminated(); // MBE is possible if the async group closing is slow } @Test @@ -2862,10 +2859,9 @@ public void issue6974Part2Case1ObserveOnConditionalHide() { // .take(10) .take(10, TimeUnit.MILLISECONDS) , flatMapMaxConcurrency) - .test() + .subscribeWith(new TestSubscriberEx<>()) .awaitDone(5, TimeUnit.SECONDS) - .assertNoErrors() - .assertComplete(); + .assertTerminated(); // MBE is possible if the async group closing is slow } /*