-
Notifications
You must be signed in to change notification settings - Fork 534
add DEF_SOURCE_LINE to ctests #1848
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
31bb7b1
to
08077f9
Compare
GoogleTest sets this property on ctest tests, and vscode-cmake-tools will use it to dramatically improve the Test Explorer user experience. CppUTest doesn't record file paths or line numbers for test groups, only for tests, so when CPPUTEST_TESTS_DETAILED=0, use the lowest line number of the tests in that group.
08077f9
to
8776b8e
Compare
Just saw there were some new commits on |
A note for anyone trying to use this with Visual Studio Code: you'll have to install the pre-release version of CMake Tools for this to work for you, at least until they put out a release that contains vscode-cmake-tools:3ab4e0dc. |
I left a bit of feedback, but directionaly I think this is good and I like the idea. @basvodde are you able to kick off the workflow? |
@thetic thanks for taking the time to review this. I think I've addressed all of the points you raised. I'm wrapping up for today. Let me know if there's anything else you want me to tweak about this PR, I'll get to it in the next day or so. |
It all looks good to me. Thanks for the contribution. We'll have to wait for Bas to merge. |
Ok. I'll merge. Looking at the CMake code. I wonder... is there a unit test framework for CMake also? It seems to include more and more logic... |
CMake has a little tool that they use internally, |
Might be interesting to consider. Part of being a unit test framework is showing that you can write unit tests for certain things. So, it could be an example for others. |
GoogleTest sets this property on ctest tests, and vscode-cmake-tools will use it to dramatically improve the Test Explorer user experience.
CppUTest doesn't record file paths or line numbers for test groups, only for tests, so when
CPPUTEST_TESTS_DETAILED=0
, use the lowest line number of the tests in that group.