Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

C++ Mocks Made Easy - An Introduction to gMock

Loading...

Sign in or sign up now!
13,253
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Mar 18, 2009

Google Tech Talks
January 22, 2008

ABSTRACT

Note: This project has been open-sourced under the name Google C++ Mocking Framework, and the project's homepage is http://code.google.com/p/googlemock/

Mock objects make unit testing easier and more effective. They cut code dependencies, make the tests fast and robust, make the test intent clear, and enable developers to easily test the interaction between components.

While an invaluable technique, mocks haven't caught on in the C++ land due to limitation of the language and lack of good tools.

gMock is a library that makes C++ mocks easy and practical. A user would describe the interface he wants to mock and gMock will automatically generate the implementation. Then the user can control the generated mock using an intuitive Domain-Specific Language (embedded in C++) that resembles English. Announced in Q4 2007, gMock has been used in over 100 projects at Google.

The primary designer of gMock will present:

What mock objects are and what they can do for you;
How gMock works;
How to use gMock to your benefit; and
Some technical challenges in developing gMock (crazy templates and macros come to mind).

If you want to write well-designed and well-tested C++ programs, this talk is for you.

Speaker: Zhanyong Wan
Zhanyong Wan is a software engineer in Google Kirkland. He is the primary author of Google Test and gMock, our in-house C++ testing infrastructures. His main interest is in writing tools to help fellow developers produce better code.

  • likes, 5 dislikes

Link to this comment:

Share to:

Top Comments

  • very nice !

  • no problem understanding him either, even considering that English is not my native.

see all

All Comments (12)

Sign In or Sign Up now to post a comment!
  • I think English is becoming a language in which a foreign accent is treated pretty much the same way as a native accent (e.g. British English or Texas American English or Scottish (horrible) accent or Russian accent etc). I can understand him but it's true that some Chinese people have horrible accents. Again, this guy speaks well.

  • I'm American and I can understand him just fine. Rest of you are just haters!

  • I beleive this talk to be of great value, the way it was presented however, made it impossible for me to keep focused... maybe i have ADHD and don't know about it, or maybe being non chinese foreigner made this talk impossible to grasp for the whole hour... sorry mr Zhanyong, i know you did your best! maybe an english transcript or legends would make it accessible for the rest of us

  • @spititan I'm a native English speaker and didn't have a problem either.

  • As a Chinese, I can understand his English perfectly... My God.

  • I couldn't understand anything he said either. :/

Loading...

0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more