Show all
Featured downloads:
mockcpp-2.1-20090825.tar.gz mockcpp-2.2-20090903.tar.gz mockcpp-2.3-20091110.tar.gz
mockcpp-2.1-20090825.tar.gz mockcpp-2.2-20090903.tar.gz mockcpp-2.3-20091110.tar.gz
mock++ is a jmock-like generic easy-of-use C++ Mock Framework, creating a mock object by using mock++ is virtually as easy as using jMock.
Current Release
mock++ 2.3 is avaliable for downloading now, the main changes of this release are:
- Automatic type deduction of integer types (long/unsigned long, int/unsigned int, short/unsigned short, char/unsigned char) is supported;
- Using cmake as the building system, rather than put MSVC project files into repository directly.
Previous Releases
mock++ 2.2:
- MSVC 2008 is supported, except for the RTTI capabilities (which means dynamic_cast does not work correctly, basically, it always returns 0).
- Supported cygwin (tested under cygwin 1.5.25-15 with g++ 3.4.4)
- Advanced Guide (English Version)
mock++ 2.1:
- down cast by dynamic_cast is supported;
- Able to specifing the lifecycle of a mock object, and the mockobject could be performed delete operation(not "::operator delete") safely.
- const reference type of return value of a mocked method is fully supported.
- ignoreReturnValue() is deprecated, actually it's not allowed to use it any more. Instead, you should always specify the return behavior for a mock specification.
- added some configure parameters to change the default settings
- some minor bugs are fixed
mock++ 2.0:
- Define mock classes for interfaces is not required any longer (Only working with g++ so far)
- Refactored some concepts to make them more clear and easy to understand
- Supporting mocking C function easily (g++ > 3 / MSVC > 6)
- Added .then(stub) after .will(stub) to make specifying complex invocation behavior much easier
- Allow specifying more order-related constraints by using multiple before()/after()
- Added some useful extensions (repeat(), increase(), throws(), startWith(), endWith(), contains(), etc.)
- Chinese User Manual
Get The Source
You can download the latest version from download page, or you can go to source page to checkout from svn to get the lastest change, in which some bugs might have been fixed.
Should you have any suggestions or questions, please mailto:dev.mockcpp@gmail.com