News for hackers. Stuff that matters.
Re:Show HN: Forbidden Fruit – Patch built-in Python objects by clarete on Wednesday April 03, 2013 @03:44PM (#5488524)
I might be wrong, but I don't think that it's actually possible to mock built-in objects (written in C, not in python) using pytest.

A very quick test would be trying to do something like this:

>>> monkeypatch(str, "blah", "bleh") >>> assert str.blah == "bleh"

I tried it here with no success though.

There are no comments on this comment yet.