vendredi 19 juin 2020

Mocking external APIs and generating fake test responses

I am working with a https://github.com/wadewegner/Force.com-Toolkit-for-NET and lost on how to go about writing unit tests.

Are there tools available to help mock my external calls to salesforce? Otherwise what is the best approach to mock a call with Moq and generate a response payload?

I have the similar question for when mocking HttpClient for other external API: what is the best approach to generate the responses so that they are maintainable if/when the external API changes?

Aucun commentaire:

Enregistrer un commentaire