File tree Expand file tree Collapse file tree 3 files changed +3
-9
lines changed
src/test/java/io/reactivex/internal/operators/maybe Expand file tree Collapse file tree 3 files changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -135,16 +135,14 @@ public void noErrorLoss() throws Exception {
135135 @ Override
136136 public void run () throws Exception {
137137 cdl1 .countDown ();
138- cdl2 .await ();
138+ cdl2 .await (5 , TimeUnit . SECONDS );
139139 }
140140 }).subscribeOn (Schedulers .single ()).test ();
141141
142142 assertTrue (cdl1 .await (5 , TimeUnit .SECONDS ));
143143
144144 to .cancel ();
145145
146- cdl2 .countDown ();
147-
148146 int timeout = 10 ;
149147
150148 while (timeout -- > 0 && errors .isEmpty ()) {
Original file line number Diff line number Diff line change @@ -138,7 +138,7 @@ public void noErrorLoss() throws Exception {
138138 @ Override
139139 public Integer call () throws Exception {
140140 cdl1 .countDown ();
141- cdl2 .await ();
141+ cdl2 .await (5 , TimeUnit . SECONDS );
142142 return 1 ;
143143 }
144144 }).subscribeOn (Schedulers .single ()).test ();
@@ -147,8 +147,6 @@ public Integer call() throws Exception {
147147
148148 to .cancel ();
149149
150- cdl2 .countDown ();
151-
152150 int timeout = 10 ;
153151
154152 while (timeout -- > 0 && errors .isEmpty ()) {
Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ public void noErrorLoss() throws Exception {
134134 public void run () {
135135 cdl1 .countDown ();
136136 try {
137- cdl2 .await ();
137+ cdl2 .await (5 , TimeUnit . SECONDS );
138138 } catch (InterruptedException ex ) {
139139 throw new RuntimeException (ex );
140140 }
@@ -145,8 +145,6 @@ public void run() {
145145
146146 to .cancel ();
147147
148- cdl2 .countDown ();
149-
150148 int timeout = 10 ;
151149
152150 while (timeout -- > 0 && errors .isEmpty ()) {
You can’t perform that action at this time.
0 commit comments