File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed
fluss-common/src/test/java/org/apache/fluss/utils Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change 1717
1818package org .apache .fluss .utils ;
1919
20- import org .junit .jupiter .api .Assertions ;
2120import org .junit .jupiter .api .Test ;
2221
2322import java .util .concurrent .CompletionException ;
@@ -142,7 +141,13 @@ void testFirstOrSuppressedCyclePrevention() {
142141 assertThat (exceptionB .getSuppressed ()).isEmpty ();
143142
144143 // verify that processing suppressed exceptions no longer causes StackOverflowError
145- Assertions .assertDoesNotThrow (() -> recursivelyProcessSuppressedExceptions (exceptionA ));
144+ Throwable thrown = null ;
145+ try {
146+ recursivelyProcessSuppressedExceptions (exceptionA );
147+ } catch (Throwable t ) {
148+ thrown = t ;
149+ }
150+ assertThat (thrown ).isNull ();
146151 }
147152
148153 @ Test
@@ -165,7 +170,13 @@ void testFirstOrSuppressedCyclePreventionThroughCauseChain() {
165170 assertThat (exceptionA .getCause ()).isEqualTo (exceptionB );
166171
167172 // verify that processing the cause chain no longer causes StackOverflowError
168- Assertions .assertDoesNotThrow (() -> recursivelyProcessCauseChain (exceptionA ));
173+ Throwable thrown = null ;
174+ try {
175+ recursivelyProcessCauseChain (exceptionA );
176+ } catch (Throwable t ) {
177+ thrown = t ;
178+ }
179+ assertThat (thrown ).isNull ();
169180 }
170181
171182 @ Test
You can’t perform that action at this time.
0 commit comments