Add static import convenience methods to Done and NotUsed (#25174)
* Add Done.done() convenience for static import * Add NotUsed.notUsed() convenience for static import
This commit is contained in:
parent
c8f4a17025
commit
5c401584c3
7 changed files with 25 additions and 6 deletions
|
|
@ -34,6 +34,7 @@ import java.util.concurrent.TimeoutException;
|
|||
import java.util.stream.Stream;
|
||||
import java.time.Duration;
|
||||
|
||||
import static akka.Done.done;
|
||||
import static akka.stream.testkit.StreamTestKit.PublisherProbeSubscription;
|
||||
import static org.junit.Assert.*;
|
||||
|
||||
|
|
@ -595,7 +596,7 @@ public class FlowTest extends StreamTest {
|
|||
.watchTermination(Keep.right())
|
||||
.to(Sink.ignore()).run(materializer);
|
||||
|
||||
assertEquals(Done.getInstance(), future.toCompletableFuture().get(3, TimeUnit.SECONDS));
|
||||
assertEquals(done(), future.toCompletableFuture().get(3, TimeUnit.SECONDS));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue