Remove unused sample references from FlowDoc{Test|Spec} (#20450)
This commit is contained in:
parent
ec74f52fe9
commit
98c56822e3
2 changed files with 0 additions and 10 deletions
|
|
@ -126,7 +126,6 @@ public class FlowDocTest extends AbstractJavaTest {
|
|||
@Test
|
||||
@SuppressWarnings("unused")
|
||||
public void compoundSourceCannotBeUsedAsKey() throws Exception {
|
||||
// #compound-source-is-not-keyed-runWith
|
||||
final Object tick = new Object();
|
||||
|
||||
final Duration oneSecond = Duration.ofSeconds(1);
|
||||
|
|
@ -138,13 +137,10 @@ public class FlowDocTest extends AbstractJavaTest {
|
|||
final Source<String, Cancellable> timerMap = timer.map(t -> "tick");
|
||||
// WRONG: returned type is not the timers Cancellable!
|
||||
// Cancellable timerCancellable = Sink.ignore().runWith(timerMap, mat);
|
||||
// #compound-source-is-not-keyed-runWith
|
||||
|
||||
// #compound-source-is-not-keyed-run
|
||||
// retain the materialized map, in order to retrieve the timer's Cancellable
|
||||
final Cancellable timerCancellable = timer.to(Sink.ignore()).run(system);
|
||||
timerCancellable.cancel();
|
||||
// #compound-source-is-not-keyed-run
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
|||
|
|
@ -73,9 +73,6 @@ class FlowDocSpec extends AkkaSpec with CompileOnlySpec {
|
|||
}
|
||||
|
||||
"compound source cannot be used as key" in {
|
||||
// FIXME #16902 This example is now turned around
|
||||
// The WRONG case has been switched
|
||||
//#compound-source-is-not-keyed-runWith
|
||||
import scala.concurrent.duration._
|
||||
case object Tick
|
||||
|
||||
|
|
@ -88,12 +85,9 @@ class FlowDocSpec extends AkkaSpec with CompileOnlySpec {
|
|||
// materialize the flow and retrieve the timers Cancellable
|
||||
val timerCancellable = Sink.ignore.runWith(timerMap)
|
||||
timerCancellable.cancel()
|
||||
//#compound-source-is-not-keyed-runWith
|
||||
|
||||
//#compound-source-is-not-keyed-run
|
||||
val timerCancellable2 = timerMap.to(Sink.ignore).run()
|
||||
timerCancellable2.cancel()
|
||||
//#compound-source-is-not-keyed-run
|
||||
}
|
||||
|
||||
"creating sources, sinks" in {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue