This adds support for coverage tracking under codecov.io.
To make this work, just create an account on codecov and merge to master. See here for an example of a generated report.
I ran into some problems in my own fork that shouldn't happen on the clean merge here.
To make this work, we have to disable the bundling of the header libraries into a single shipped library because the code there makes CMake use the merged library for compilation when assembling tests and coverage tools will try to look into the repository for files (and the merged file won't exist on master). You'll see I've added a new FLEXCLASS_BUNDLE option that allows us to control whether we bundle the headers. I've also added code to automatically disable bundling and remove this new option when coverage is enabled (removing the option improves UX when using tools like ccmake).
GitHub actions are quite a pain to test, so we might run into issues here, please reach out if we do.
Side note
We also have Coveralls as an option, but to make it work we need to add the installation of {{lcov}} on the GitHub action and I'd rather avoid that. We can still go that route if we want, we just have to replace the job I've set up here for:
This adds support for coverage tracking under codecov.io. To make this work, just create an account on codecov and merge to master. See here for an example of a generated report.
I ran into some problems in my own fork that shouldn't happen on the clean merge here.
To make this work, we have to disable the bundling of the header libraries into a single shipped library because the code there makes CMake use the merged library for compilation when assembling tests and coverage tools will try to look into the repository for files (and the merged file won't exist on
master
). You'll see I've added a newFLEXCLASS_BUNDLE
option that allows us to control whether we bundle the headers. I've also added code to automatically disable bundling and remove this new option when coverage is enabled (removing the option improves UX when using tools likeccmake
).GitHub actions are quite a pain to test, so we might run into issues here, please reach out if we do.
Side note
We also have Coveralls as an option, but to make it work we need to add the installation of {{lcov}} on the GitHub action and I'd rather avoid that. We can still go that route if we want, we just have to replace the job I've set up here for:
See here an example for the Coveralls report.