Akka.Cluster.Tools.Tests.MultiNode.Singleton.ClusterSingletonManagerChaos2Spec.ClusterSingletonManager_in_chaotic_cluster_should_take_over_when_tree_oldest_nodes_crash_in_6_nodes_cluster C# (CSharp) Метод

ClusterSingletonManager_in_chaotic_cluster_should_take_over_when_tree_oldest_nodes_crash_in_6_nodes_cluster() приватный Метод

        public void ClusterSingletonManager_in_chaotic_cluster_should_take_over_when_tree_oldest_nodes_crash_in_6_nodes_cluster()
        {
            Within(TimeSpan.FromSeconds(90), () =>
            {
                var memberProbe = CreateTestProbe();
                Cluster.Subscribe(memberProbe.Ref, new[] { typeof(ClusterEvent.MemberUp) });
                memberProbe.ExpectMsg<ClusterEvent.CurrentClusterState>();

                Join(_config.First, _config.First);
                AwaitMemberUp(memberProbe, _config.First);

                Join(_config.Second, _config.First);
                AwaitMemberUp(memberProbe, _config.Second, _config.First);

                Join(_config.Third, _config.First);
                AwaitMemberUp(memberProbe, _config.Third, _config.Second, _config.First);

                Join(_config.Fourth, _config.First);
                AwaitMemberUp(memberProbe, _config.Fourth, _config.Third, _config.Second, _config.First);

                // mute logging of deadLetters during shutdown of systems
                if (!Log.IsDebugEnabled)
                    Sys.EventStream.Publish(new Mute(new WarningFilter()));
                EnterBarrier("logs-muted");

                Crash(_config.First, _config.Second, _config.Third);
                EnterBarrier("after-crash");
                RunOn(() =>
                {
                    ExpectMsg<EchoStarted>();
                }, _config.Fourth);
                EnterBarrier("_config.Fourth-active");

                RunOn(() =>
                {
                    Echo(_config.Fourth).Tell("hello");
                    var address = ExpectMsg<IActorRef>(TimeSpan.FromSeconds(3)).Path.Address;
                    Assert.Equal(address, GetAddress(_config.Fourth));
                }, _config.Controller);
                EnterBarrier("_config.Fourth-verified");
            });
        }