Pytest with Eric

Learn to write production level Python Unit Tests with Pytest

Have you heard of monkeypatch but have no idea what it means?

Or maybe you’ve even seen it in your company’s code base and wondered why your colleagues use it.

Rather than go through complex documentation or a bunch of Stack Overflow posts, let’s understand what is monkeypatching at a high level and when and how we can use it to improve Unit Testing.

Read more »

So you’re tasked with building a service that talks to external REST API.

You use the Requests or similar library, whip up some GET or POST methods and voila! All done.

Easy peasy, right?

Well not so. If you’re doing it for a hobby or quick side project then yes.

But as a professional developer, you know that you’ve to account for all edge cases.

The challenge when dealing with external APIs is that the behaviour is outside your control.

Schema or payload changes, new error codes, and updated speed caps are some problems that may plague you.

Read more »
0%