Akka.Streams.Tests.Dsl.SinkSpec.A_Sink_must_be_composable_without_importing_modules C# (CSharp) Method

A_Sink_must_be_composable_without_importing_modules() private method

        public void A_Sink_must_be_composable_without_importing_modules()
        {
            var probes = CreateProbes();
            var sink = Sink.FromGraph(GraphDsl.Create(b =>
            {
                var broadcast = b.Add(new Broadcast<int>(3));
                for (var i = 0; i < 3; i++)
                {
                    var closure = i;
                    b.From(broadcast.Out(i))
                        .Via(Flow.Create<int>().Where(x => x == closure))
                        .To(Sink.FromSubscriber(probes[i]));
                }
                return new SinkShape<int>(broadcast.In);
            }));
            Source.From(new[] {0, 1, 2}).RunWith(sink, Materializer);

            var subscriptions = probes.Select(p => p.ExpectSubscription()).ToList();
            subscriptions.ForEach(s=>s.Request(3));
            for (var i = 0; i < probes.Length; i++)
                probes[i].ExpectNext(i);
            probes.ForEach(p => p.ExpectComplete());
        }