!str - Switches Sink.publisher to use a boolean to indicate fanout rather than a number of allowed subscribers

This commit is contained in:
Viktor Klang 2015-11-03 12:53:24 +01:00
parent f839a1f85d
commit 6cfa4df800
53 changed files with 221 additions and 212 deletions

View file

@ -22,7 +22,7 @@ class TestPublisherSubscriberSpec extends AkkaSpec {
"have all events accessible from manual probes" in assertAllStagesStopped {
val upstream = TestPublisher.manualProbe[Int]()
val downstream = TestSubscriber.manualProbe[Int]()
Source(upstream).runWith(Sink.publisher(1))(materializer).subscribe(downstream)
Source(upstream).runWith(Sink.publisher(false))(materializer).subscribe(downstream)
val upstreamSubscription = upstream.expectSubscription()
val downstreamSubscription: Subscription = downstream.expectEventPF { case OnSubscribe(sub) sub }
@ -46,7 +46,7 @@ class TestPublisherSubscriberSpec extends AkkaSpec {
"handle gracefully partial function that is not suitable" in assertAllStagesStopped {
val upstream = TestPublisher.manualProbe[Int]()
val downstream = TestSubscriber.manualProbe[Int]()
Source(upstream).runWith(Sink.publisher(1))(materializer).subscribe(downstream)
Source(upstream).runWith(Sink.publisher(false))(materializer).subscribe(downstream)
val upstreamSubscription = upstream.expectSubscription()
val downstreamSubscription: Subscription = downstream.expectEventPF { case OnSubscribe(sub) sub }