-
Notifications
You must be signed in to change notification settings - Fork 105
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
TEST: add error checking and exit in gtest #1083
TEST: add error checking and exit in gtest #1083
Conversation
Conclusion: there was a bad handling of error when there is no port available in the device. With this patch, we can see that all gtest are successfully skipped, with the message
For the record, the stack detecting that there is no port open on the ib_device is the following:
|
The CI is now segfault-free, so this patch should unblock the other PRs One error remains:
which is probably due to a legit error in the node. If this error persist we could decide to skip and not assert in case of error status |
When a gtest unit is skipped or failed, using gtest macros like
GTEST_ASSERT_EQ
, orGTEST_SKIP
, the program only exits the current function, but not the whole test. Therefore, the error/skip must be propagated through all frames of the unit test. Bottom line, each time we call a function that is susceptible to call one of this macro, we need to check on return the test status and return if relevant.Related issue: