From 98c56822e3d1089eea210152c1e56f03dd116c73 Mon Sep 17 00:00:00 2001 From: Captain1653 Date: Wed, 11 Aug 2021 19:29:00 +0300 Subject: [PATCH] Remove unused sample references from FlowDoc{Test|Spec} (#20450) --- akka-docs/src/test/java/jdocs/stream/FlowDocTest.java | 4 ---- akka-docs/src/test/scala/docs/stream/FlowDocSpec.scala | 6 ------ 2 files changed, 10 deletions(-) diff --git a/akka-docs/src/test/java/jdocs/stream/FlowDocTest.java b/akka-docs/src/test/java/jdocs/stream/FlowDocTest.java index 5b69c16daf..f6ee45791b 100644 --- a/akka-docs/src/test/java/jdocs/stream/FlowDocTest.java +++ b/akka-docs/src/test/java/jdocs/stream/FlowDocTest.java @@ -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 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 diff --git a/akka-docs/src/test/scala/docs/stream/FlowDocSpec.scala b/akka-docs/src/test/scala/docs/stream/FlowDocSpec.scala index e6ff6ed4e8..dedc1c8829 100644 --- a/akka-docs/src/test/scala/docs/stream/FlowDocSpec.scala +++ b/akka-docs/src/test/scala/docs/stream/FlowDocSpec.scala @@ -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 {