My team and I are looking for a mocking framework for C and C++ on Linux. We have a huge codebase that we want to test, so the most important thing for us is having a mocking framework that will allow us not to change our legacy code in order to write tests. Does anyone know such mocking framework?
2 Answers
We use Typemock's Isolator++, this is the most friendly mocking tool i encountered for C. The mocking abilities is extremely friendly because 100% of your code remains comepletely untouched. This framework allows you to fake every kind of method or class and control the methods behavior. It also integrates with GoogleTest which we use in my team and it works smoothly.
-
Thanks Ilan! we took your advice and we're evaluating Isolator++ now. So far it looks great!– HilaBCommented Jun 3, 2018 at 9:40
My team and I also use Isolator++. I like how it integrates with Google Test.
-
Why would you say it does not provide an answer? the question is: does anyone know a mocking framework for C/C++ on Linux? my answer is: Isolator++.– JamesRCommented Jun 10, 2018 at 8:46
-
Sorry, it is a 'me too'. 'Not an answer' was the best flag I could find (downvoting was also an option). This was already suggested as an answer. If you have any factual information to add to that answer (which you don't in this text), edit it in or add a comment there.– user416Commented Jun 10, 2018 at 9:12