File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
jupiter-tests/src/test/java/org/junit/jupiter Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ void failUsableAsAnExpression() {
145145 long count = Stream .empty ()
146146 .peek (element -> fail ("peek should never be called" ))
147147 .filter (element -> fail ("filter should never be called" , new Throwable ("cause" )))
148- .map (element -> fail (new Throwable ("map should never be called" )))
148+ .map (element -> Assertions .< Throwable > fail (new Throwable ("map should never be called" )))
149149 .sorted ((e1 , e2 ) -> fail (() -> "sorted should never be called" ))
150150 .count ();
151151 // @formatter:on
Original file line number Diff line number Diff line change 3636import java .util .function .UnaryOperator ;
3737
3838import org .assertj .core .api .Condition ;
39+ import org .jspecify .annotations .Nullable ;
3940import org .junit .jupiter .api .AfterEach ;
4041import org .junit .jupiter .api .BeforeEach ;
4142import org .junit .jupiter .api .Test ;
@@ -61,10 +62,10 @@ class PreInterruptCallbackTests extends AbstractJupiterTestEngineTests {
6162 private static final String TC = "test" ;
6263 private static final String TIMEOUT_ERROR_MSG = TC + "() timed out after 1 microsecond" ;
6364 private static final AtomicBoolean interruptedTest = new AtomicBoolean ();
64- private static final CompletableFuture <Void > testThreadExecutionDone = new CompletableFuture <>();
65- private static final AtomicReference <Thread > interruptedTestThread = new AtomicReference <>();
65+ private static final CompletableFuture <? > testThreadExecutionDone = new CompletableFuture <>();
66+ private static final AtomicReference <@ Nullable Thread > interruptedTestThread = new AtomicReference <>();
6667 private static final AtomicBoolean interruptCallbackShallThrowException = new AtomicBoolean ();
67- private static final AtomicReference <PreInterruptContext > calledPreInterruptContext = new AtomicReference <>();
68+ private static final AtomicReference <@ Nullable PreInterruptContext > calledPreInterruptContext = new AtomicReference <>();
6869
6970 @ BeforeEach
7071 void setUp () {
You can’t perform that action at this time.
0 commit comments