23 Apr 2013, 12:14
Generic-user-small

Erick van Rijk (2 posts)

Dear Mr. Grenning. I am enjoying your book so-far. I’ve completed the the unity test cases without much effort and arrived at the time where I need to start using CppUTest.

However, when changing to CppUTest, I’m running into problems with unresolved references to _RuntimeError. As you noted in http://forums.pragprog.com/forums/123/topics/9286 some steps could resolve my issues. However it seems that I’m missing a vital step.

My LedDriver.h includes RuntimeErrorStub.h which in turn includes RuntimeError.h. I have included LedDriver.h as an extern C in my LedDriverTest.cpp file, so the compiler should resolve this correctly. And i’ve included LedDriver.h to LedDriver.c (A bit obvious). I still get the following error /cygdrive/c/Users/user/workspace/BookCode/SandBoxCPP/src/LedDriver/LedDriver.c:52: undefined reference to _RuntimeError’ `

I’m using Eclipse CDT JUNO and cygwin gcc. Perhaps you could revisit your source code that you put up for download, and update it with the latest versions of Unity and CPPUTest. (they were both outdated and contained bugs). Any help/suggestions would be appreciated.

  You must be logged in to comment