Tag: graphql-dotnet
-
Mocking and unit testing graphql-dotnet
0 I’m using graphql-dotnet library to query some GraphQL APIs from my C# code. Is there a way to easily mock the GraphQLHttpClient in unit tests? c# unit-testing graphql moq graphql-dotnet Share Follow asked 1 hour ago Dawid RutkowskiDawid Rutkowski 2,66711 gold badge3030 silver badges3737 bronze badges 2 what did you try yourself? – MakePeaceGreatAgain 42…
-
How to upload file using graphql-client?
0 How can I make a mutation call from a client and upload a file? I can do it in the editor (screen) But I cannot figure out how to make the same from a client var request = new GraphQLRequest { Query = query, Variables = new { id = "id" }, }; var…
-
How to deserialize Graphql Response
0 Hi I have a graphql Response after Mutating {{ "carCreate": { "car": { "id": "TestId" } } }} I want to Desealize it I am using The following Code var graphQlClient = new GraphQLHttpClient(AppConfig.GraphQlUrl, new NewtonsoftJsonSerializer()); I have tried to resolve with the following code var response = await graphQlClient.SendMutationAsync<CarCreate>(request); My Created Model is…