public void BatchRunReportsRequestObject()
        {
            moq::Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient> mockGrpcClient = new moq::Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient>(moq::MockBehavior.Strict);
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Entity   = new Entity(),
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            BatchRunReportsResponse expectedResponse = new BatchRunReportsResponse
            {
                Reports =
                {
                    new RunReportResponse(),
                },
            };

            mockGrpcClient.Setup(x => x.BatchRunReports(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(expectedResponse);
            AlphaAnalyticsDataClient client   = new AlphaAnalyticsDataClientImpl(mockGrpcClient.Object, null);
            BatchRunReportsResponse  response = client.BatchRunReports(request);

            xunit::Assert.Same(expectedResponse, response);
            mockGrpcClient.VerifyAll();
        }
        public async stt::Task BatchRunReportsRequestObjectAsync()
        {
            moq::Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient> mockGrpcClient = new moq::Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient>(moq::MockBehavior.Strict);
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Entity   = new Entity(),
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            BatchRunReportsResponse expectedResponse = new BatchRunReportsResponse
            {
                Reports =
                {
                    new RunReportResponse(),
                },
            };

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

            xunit::Assert.Same(expectedResponse, responseCallSettings);
            BatchRunReportsResponse responseCancellationToken = await client.BatchRunReportsAsync(request, st::CancellationToken.None);

            xunit::Assert.Same(expectedResponse, responseCancellationToken);
            mockGrpcClient.VerifyAll();
        }
        public void BatchRunReportsRequestObject()
        {
            moq::Mock <BetaAnalyticsData.BetaAnalyticsDataClient> mockGrpcClient = new moq::Mock <BetaAnalyticsData.BetaAnalyticsDataClient>(moq::MockBehavior.Strict);
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Property = "propertyc9b48d1a",
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            BatchRunReportsResponse expectedResponse = new BatchRunReportsResponse
            {
                Reports =
                {
                    new RunReportResponse(),
                },
                Kind = "kindf7aa39d9",
            };

            mockGrpcClient.Setup(x => x.BatchRunReports(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(expectedResponse);
            BetaAnalyticsDataClient client   = new BetaAnalyticsDataClientImpl(mockGrpcClient.Object, null);
            BatchRunReportsResponse response = client.BatchRunReports(request);

            xunit::Assert.Same(expectedResponse, response);
            mockGrpcClient.VerifyAll();
        }
 /// <summary>Snippet for BatchRunReports</summary>
 public void BatchRunReports_RequestObject()
 {
     // Snippet: BatchRunReports(BatchRunReportsRequest,CallSettings)
     // Create client
     AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.Create();
     // Initialize request argument(s)
     BatchRunReportsRequest request = new BatchRunReportsRequest();
     // Make the request
     BatchRunReportsResponse response = alphaAnalyticsDataClient.BatchRunReports(request);
     // End snippet
 }
        /// <summary>Snippet for BatchRunReportsAsync</summary>
        public async Task BatchRunReportsAsync_RequestObject()
        {
            // Snippet: BatchRunReportsAsync(BatchRunReportsRequest,CallSettings)
            // Additional: BatchRunReportsAsync(BatchRunReportsRequest,CancellationToken)
            // Create client
            AlphaAnalyticsDataClient alphaAnalyticsDataClient = await AlphaAnalyticsDataClient.CreateAsync();

            // Initialize request argument(s)
            BatchRunReportsRequest request = new BatchRunReportsRequest();
            // Make the request
            BatchRunReportsResponse response = await alphaAnalyticsDataClient.BatchRunReportsAsync(request);

            // End snippet
        }
        public async Task BatchRunReportsAsync()
        {
            Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient> mockGrpcClient = new Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient>(MockBehavior.Strict);
            BatchRunReportsRequest  request          = new BatchRunReportsRequest();
            BatchRunReportsResponse expectedResponse = new BatchRunReportsResponse();

            mockGrpcClient.Setup(x => x.BatchRunReportsAsync(request, It.IsAny <CallOptions>()))
            .Returns(new Grpc.Core.AsyncUnaryCall <BatchRunReportsResponse>(Task.FromResult(expectedResponse), null, null, null, null));
            AlphaAnalyticsDataClient client   = new AlphaAnalyticsDataClientImpl(mockGrpcClient.Object, null);
            BatchRunReportsResponse  response = await client.BatchRunReportsAsync(request);

            Assert.Same(expectedResponse, response);
            mockGrpcClient.VerifyAll();
        }
        public void BatchRunReports()
        {
            Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient> mockGrpcClient = new Mock <AlphaAnalyticsData.AlphaAnalyticsDataClient>(MockBehavior.Strict);
            BatchRunReportsRequest  request          = new BatchRunReportsRequest();
            BatchRunReportsResponse expectedResponse = new BatchRunReportsResponse();

            mockGrpcClient.Setup(x => x.BatchRunReports(request, It.IsAny <CallOptions>()))
            .Returns(expectedResponse);
            AlphaAnalyticsDataClient client   = new AlphaAnalyticsDataClientImpl(mockGrpcClient.Object, null);
            BatchRunReportsResponse  response = client.BatchRunReports(request);

            Assert.Same(expectedResponse, response);
            mockGrpcClient.VerifyAll();
        }
 /// <summary>Snippet for BatchRunReports</summary>
 /// <remarks>
 /// This snippet has been automatically generated for illustrative purposes only.
 /// It may require modifications to work in your environment.
 /// </remarks>
 public void BatchRunReportsRequestObject()
 {
     // Create client
     AlphaAnalyticsDataClient alphaAnalyticsDataClient = AlphaAnalyticsDataClient.Create();
     // Initialize request argument(s)
     BatchRunReportsRequest request = new BatchRunReportsRequest
     {
         Entity   = new Entity(),
         Requests =
         {
             new RunReportRequest(),
         },
     };
     // Make the request
     BatchRunReportsResponse response = alphaAnalyticsDataClient.BatchRunReports(request);
 }
Example #9
0
 /// <summary>Snippet for BatchRunReports</summary>
 /// <remarks>
 /// This snippet has been automatically generated for illustrative purposes only.
 /// It may require modifications to work in your environment.
 /// </remarks>
 public void BatchRunReportsRequestObject()
 {
     // Create client
     BetaAnalyticsDataClient betaAnalyticsDataClient = BetaAnalyticsDataClient.Create();
     // Initialize request argument(s)
     BatchRunReportsRequest request = new BatchRunReportsRequest
     {
         Property = "",
         Requests =
         {
             new RunReportRequest(),
         },
     };
     // Make the request
     BatchRunReportsResponse response = betaAnalyticsDataClient.BatchRunReports(request);
 }
Example #10
0
        /// <summary>Snippet for BatchRunReportsAsync</summary>
        /// <remarks>
        /// This snippet has been automatically generated for illustrative purposes only.
        /// It may require modifications to work in your environment.
        /// </remarks>
        public async Task BatchRunReportsRequestObjectAsync()
        {
            // Create client
            BetaAnalyticsDataClient betaAnalyticsDataClient = await BetaAnalyticsDataClient.CreateAsync();

            // Initialize request argument(s)
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Property = "",
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            // Make the request
            BatchRunReportsResponse response = await betaAnalyticsDataClient.BatchRunReportsAsync(request);
        }
        /// <summary>Snippet for BatchRunReportsAsync</summary>
        /// <remarks>
        /// This snippet has been automatically generated for illustrative purposes only.
        /// It may require modifications to work in your environment.
        /// </remarks>
        public async Task BatchRunReportsRequestObjectAsync()
        {
            // Create client
            AlphaAnalyticsDataClient alphaAnalyticsDataClient = await AlphaAnalyticsDataClient.CreateAsync();

            // Initialize request argument(s)
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Entity   = new Entity(),
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            // Make the request
            BatchRunReportsResponse response = await alphaAnalyticsDataClient.BatchRunReportsAsync(request);
        }
Example #12
0
        /// <summary>Snippet for BatchRunReportsAsync</summary>
        public async Task BatchRunReportsRequestObjectAsync()
        {
            // Snippet: BatchRunReportsAsync(BatchRunReportsRequest, CallSettings)
            // Additional: BatchRunReportsAsync(BatchRunReportsRequest, CancellationToken)
            // Create client
            BetaAnalyticsDataClient betaAnalyticsDataClient = await BetaAnalyticsDataClient.CreateAsync();

            // Initialize request argument(s)
            BatchRunReportsRequest request = new BatchRunReportsRequest
            {
                Property = "",
                Requests =
                {
                    new RunReportRequest(),
                },
            };
            // Make the request
            BatchRunReportsResponse response = await betaAnalyticsDataClient.BatchRunReportsAsync(request);

            // End snippet
        }