/Python_Unittest_Mocking

A small project in which I am attempting to achieve 100% unit test coverage on an API through the use of mock patching.

Primary LanguagePythonApache License 2.0Apache-2.0

Python Unittest Mocking

This project is a small task set within QA Academy in order to practice unit test mocking. I am attempting to achieve 100% unit test coverage on a Flask API, through the use of mock patching.

Description

For this task, I will be using unittest.mock.patch() as a function decorator - changing the behaviour of how a particular function behaves.

In particular, I will be mock patching a number of HTTP responses to external API's, so that we do not actually need to be connected to the internet in order to test the application.

Authors

Joshua Higginson - QA Consulting