Boost logo

Boost Users :

Subject: Re: [Boost-users] [Test] Where to learn about boost::itest::mock_object?
From: Richard (legalize+jeeves_at_[hidden])
Date: 2014-01-19 22:29:02


[Please do not mail me a copy of your followup]

boost-users_at_[hidden] spake the secret code
<kkfsap$lo7$1_at_[hidden]> thusly:

>[...] I would instead recommend using another mock object
>library in conjunction with Boost.Test such as googlemock or Turtle.

I have since looked into this and I would recommend Turtle.

<http://turtle.sourceforge.net>

It has a simple, clean and easy syntax with very little boilerplate
that you need to write in order to "callables" (objects providing an
implementation of operator(), function pointers, std::function, etc.),
mock interfaces and template arguments. (The author and I are discussing
ways to make mocking template arguments, also known as Concepts, easier.)

Unfortunately googlemock now requires the use of googletest as a link
dependency. When I tried MockCpp, it required too much repetitive
boiler plate for my tastes.

-- 
"The Direct3D Graphics Pipeline" free book <http://tinyurl.com/d3d-pipeline>
     The Computer Graphics Museum <http://computergraphicsmuseum.org>
         The Terminals Wiki <http://terminals.classiccmp.org>
  Legalize Adulthood! (my blog) <http://legalizeadulthood.wordpress.com>

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net