public void GetSharedCriterion()
        {
            moq::Mock <SharedCriterionService.SharedCriterionServiceClient> mockGrpcClient = new moq::Mock <SharedCriterionService.SharedCriterionServiceClient>(moq::MockBehavior.Strict);
            GetSharedCriterionRequest request = new GetSharedCriterionRequest
            {
                ResourceNameAsSharedCriterionName = gagvr::SharedCriterionName.FromCustomerSharedCriterion("[CUSTOMER]", "[SHARED_CRITERION]"),
            };
            gagvr::SharedCriterion expectedResponse = new gagvr::SharedCriterion
            {
                ResourceNameAsSharedCriterionName = gagvr::SharedCriterionName.FromCustomerSharedCriterion("[CUSTOMER]", "[SHARED_CRITERION]"),
                SharedSetAsSharedSetName          = gagvr::SharedSetName.FromCustomerSharedSet("[CUSTOMER]", "[SHARED_SET]"),
                Keyword           = new gagvc::KeywordInfo(),
                Type              = gagve::CriterionTypeEnum.Types.CriterionType.Location,
                YoutubeVideo      = new gagvc::YouTubeVideoInfo(),
                YoutubeChannel    = new gagvc::YouTubeChannelInfo(),
                Placement         = new gagvc::PlacementInfo(),
                MobileAppCategory = new gagvc::MobileAppCategoryInfo(),
                MobileApplication = new gagvc::MobileApplicationInfo(),
                CriterionId       = 8584655242409302840L,
            };

            mockGrpcClient.Setup(x => x.GetSharedCriterion(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(expectedResponse);
            SharedCriterionServiceClient client   = new SharedCriterionServiceClientImpl(mockGrpcClient.Object, null);
            gagvr::SharedCriterion       response = client.GetSharedCriterion(request.ResourceName);

            Assert.AreEqual(expectedResponse, response);
            mockGrpcClient.VerifyAll();
        }
        public async stt::Task GetSharedCriterionRequestObjectAsync()
        {
            moq::Mock <SharedCriterionService.SharedCriterionServiceClient> mockGrpcClient = new moq::Mock <SharedCriterionService.SharedCriterionServiceClient>(moq::MockBehavior.Strict);
            GetSharedCriterionRequest request = new GetSharedCriterionRequest
            {
                ResourceNameAsSharedCriterionName = gagvr::SharedCriterionName.FromCustomerSharedCriterion("[CUSTOMER]", "[SHARED_CRITERION]"),
            };
            gagvr::SharedCriterion expectedResponse = new gagvr::SharedCriterion
            {
                ResourceNameAsSharedCriterionName = gagvr::SharedCriterionName.FromCustomerSharedCriterion("[CUSTOMER]", "[SHARED_CRITERION]"),
                SharedSetAsSharedSetName          = gagvr::SharedSetName.FromCustomerSharedSet("[CUSTOMER]", "[SHARED_SET]"),
                Keyword           = new gagvc::KeywordInfo(),
                Type              = gagve::CriterionTypeEnum.Types.CriterionType.Location,
                YoutubeVideo      = new gagvc::YouTubeVideoInfo(),
                YoutubeChannel    = new gagvc::YouTubeChannelInfo(),
                Placement         = new gagvc::PlacementInfo(),
                MobileAppCategory = new gagvc::MobileAppCategoryInfo(),
                MobileApplication = new gagvc::MobileApplicationInfo(),
                CriterionId       = 8584655242409302840L,
            };

            mockGrpcClient.Setup(x => x.GetSharedCriterionAsync(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(new grpccore::AsyncUnaryCall <gagvr::SharedCriterion>(stt::Task.FromResult(expectedResponse), null, null, null, null));
            SharedCriterionServiceClient client = new SharedCriterionServiceClientImpl(mockGrpcClient.Object, null);
            gagvr::SharedCriterion       responseCallSettings = await client.GetSharedCriterionAsync(request, gaxgrpc::CallSettings.FromCancellationToken(st::CancellationToken.None));

            Assert.AreEqual(expectedResponse, responseCallSettings);
            gagvr::SharedCriterion responseCancellationToken = await client.GetSharedCriterionAsync(request, st::CancellationToken.None);

            Assert.AreEqual(expectedResponse, responseCancellationToken);
            mockGrpcClient.VerifyAll();
        }