Flexmock is a Python mock/stub/spy library used to http://www.aliyun.com/zixun/aggregation/13726.html the mock tools for >rails unit tests.
Its API 17885.html "> Inspired by the same name of Ruby Library, however, it is not a Python flexmock, the goal is to clone Ruby version. Instead, it focuses on providing a Python program for testing and, to the extent possible, full support for unobtrusive creation of fake objects. The features of Flexmock are simple and intuitive, the APIs are very compact and some handy shorthand methods are available to designers.
Flexmock 0.9.4 This version adds getter properties and non-invocation properties that support stub return values. Added support for custom matching objects to With_args (), strict function signature checks, support for chained attributes and ITER support mock objects. Should_call () is fixed, And_return () is returned by default, no fixed, use feature = Return_value style creation, will now use Replace_with () instead of should_receive (redemption value). Flexmock PyPy and Jython test work in this release.
Software Information: http://has207.github.com/flexmock/
Download Address: http://pypi.python.org/packages/source/f/flexmock/flexmock-0.9.4.tar.gz#md5=69c3186ff2d313794800b07cad34a209