jeudi 25 juillet 2019

How to write a unit test for a Flask Restplus application using python unittest framework?

I'm trying to write a unit test framework in Python for my Flask restplus application. However, the resources that I find are all using real http calls to the services. I think unit tests are for individual methods and making a real call would count as integration.

How do I mock requests and the assert the method's output to expected value in an api method?

Aucun commentaire:

Enregistrer un commentaire