0
//myfuncs.h
void func1(void);

void func2(void;

I'm doing unit testing. Using CMock with ceedling, is there any way to mock func1(), but run func2() as it was originally written?

Peter Kapteyn
  • 354
  • 1
  • 13

1 Answers1

2

To my knowledge, you can't. You must split the header file into two and generate mocks for one of them.

There are unit test frameworks that can mock one or more functions in a header file, Nala (which I'm maintaining) for example. But I guess you want to use CMock with Ceedling, so it's not really an option.

Erik Moqvist
  • 171
  • 1
  • 3