SUBSCRIBE
NOW!

How To Mock Patch A Function (Testing Python With Pytest)

Cameron Maske

Mon. Aug. 20, 2018 12:42pm

In this video, see how to use mock to patch a random integer function to return the same number each time to make the code easier to test.

Play around with this code in your browser: https://repl.it/@cameronmaske/How-To-Mock-Patch-A-Function-Testing-Python-With-Pytest

You can also find me on:
Twitter: https://twitter.com/cameronmaske
Personal Site: https://cameronmaske.com/

Techie Youth | Watch More Videos | Get Involved