Using the C/C++ Unit Testing Support plugin along with the CppUTest Runner worked for me.
Here is the documentation I wrote for myself when I installed it:
- Install the C/C++ Unit Testing Support plugin:
* Open 'Help > Installation Details', in 'Installed Sofware, check whether 'C/C++ Unit Testing Support,
if not continue with the following steps.
* Open 'Help > Install New Software...'
* In 'Work with' select '--All Available Sites--'
* Enter 'Unit' in the search field.
* Select 'CDT Optional Features > C/C++ Unit Testing Support' and click 'Next >'
- Install the CppUTest Runner:
* Download it from
https://github.com/tcmak/CppUTestEclipseJunoTestRunner * Copy the following artifacts to C:/eclipse/dropins/CppUTest':
bin/org/ to org/
META-INF/
plugin.properties
plugin.xml
* Start Eclipse from a command shell with the following command: 'eclipse -clean -console -consoleLog'
- Create a run configuration right clicking on the project and selecting 'Run As > Run Configurations... > C/C++ Unit':
* Main > Project: 'YourApplication'
* Main > C/C++ Application: 'Debug/YourApplication.exe'
* Arguments > Program arguments: 'r1 -v1'
* C/C++ Testing > Test Runner: CppUTest Tests Runner