public void UpdatePage() { moq::Mock <Pages.PagesClient> mockGrpcClient = new moq::Mock <Pages.PagesClient>(moq::MockBehavior.Strict); UpdatePageRequest request = new UpdatePageRequest { Page = new Page(), UpdateMask = new wkt::FieldMask(), }; Page expectedResponse = new Page { PageName = PageName.FromProjectLocationAgentFlowPage("[PROJECT]", "[LOCATION]", "[AGENT]", "[FLOW]", "[PAGE]"), DisplayName = "display_name137f65c2", Form = new Form(), EntryFulfillment = new Fulfillment(), TransitionRoutes = { new TransitionRoute(), }, EventHandlers = { new EventHandler(), }, TransitionRouteGroupsAsTransitionRouteGroupNames = { TransitionRouteGroupName.FromProjectLocationAgentFlowTransitionRouteGroup("[PROJECT]", "[LOCATION]", "[AGENT]", "[FLOW]", "[TRANSITION_ROUTE_GROUP]"), }, }; mockGrpcClient.Setup(x => x.UpdatePage(request, moq::It.IsAny <grpccore::CallOptions>())).Returns(expectedResponse); PagesClient client = new PagesClientImpl(mockGrpcClient.Object, null); Page response = client.UpdatePage(request.Page, request.UpdateMask); xunit::Assert.Same(expectedResponse, response); mockGrpcClient.VerifyAll(); }