Akka.Streams.Tests.Actor.ActorSubscriberSpec.ActorSubscriberSpec_should_not_deliver_more_after_cancel C# (CSharp) Method

ActorSubscriberSpec_should_not_deliver_more_after_cancel() private method

        public void ActorSubscriberSpec_should_not_deliver_more_after_cancel()
        {
            var actorRef = Source.From(Enumerable.Range(1, 5))
                    .RunWith(Sink.ActorSubscriber<int>(ManualSubscriber.Props(TestActor)), Sys.Materializer());
            actorRef.Tell("ready");
            ExpectMsg<OnNext>().Element.Should().Be(1);
            ExpectMsg<OnNext>().Element.Should().Be(2);
            actorRef.Tell("requestAndCancel");
            ExpectNoMsg(200);
        }