Exemplo n.º 1
0
        public void InitializeAndShutdownGrpcEnvironment()
        {
            var env = GrpcEnvironment.GetInstance();

            Assert.IsNotNull(env.CompletionQueue);
            GrpcEnvironment.Shutdown();
        }
Exemplo n.º 2
0
        public void SubsequentInvocations()
        {
            var env1 = GrpcEnvironment.GetInstance();
            var env2 = GrpcEnvironment.GetInstance();

            Assert.IsTrue(object.ReferenceEquals(env1, env2));
            GrpcEnvironment.Shutdown();
            GrpcEnvironment.Shutdown();
        }
Exemplo n.º 3
0
        public void InitializeAfterShutdown()
        {
            var env1 = GrpcEnvironment.GetInstance();

            GrpcEnvironment.Shutdown();

            var env2 = GrpcEnvironment.GetInstance();

            GrpcEnvironment.Shutdown();

            Assert.IsFalse(object.ReferenceEquals(env1, env2));
        }