Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Simple Mocking for Python. Simple yet powerful. Uses frame/global analysis instead of __import__. Is a fork of Ian Bicking's minimock.
Python
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
LICENSE
README
smock.py

README

smock is Simple Mock for Python.

Fork of Ian Bicking's minimock.

Features:
    * monkey patching (replacing of original functions on-the-fly)
    * searching for functions through stack frame analysis
        (no ugly stupid __import__ asspain)
    * object specification through plain string like 'os.fork'
    * mocked objects call history
    * easy creating of simple mocks like return this or call that

Everything except call history is made by Ian Bicking.
See his absorbing blog at http://blog.ianbicking.org/.
Something went wrong with that request. Please try again.