-
Notifications
You must be signed in to change notification settings - Fork 208
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
many unit tests report event count errors as hex #418
Comments
In reviewing the error reporting in general, I'm wondering if we want to use some macros and some global variables rather than having so much duplicated code in each fn. |
Yes, I am a big fan of macro-izing many of the repetitive unit test constructs. In particular there should be a at least macro to call a function and check its int32 return code (very common). I have an example of such a macro in nasa/sample_lib#11 But updating all the existing test cases is extremely tedious and time consuming.... |
Raises hand to volunteer to do at least sb_UT.c as a "demo" |
Great!! No complaints from me about that! |
Point of interest: my sample of sb_UT.c went from 10,487 lines of code to 6,878 lines, a roughly 35% reduction in code size for the UT. Check it out! :D |
@skliper would like to review the sb_UT.c changes at an upcoming CCB meeting. |
@CDKnightNASA could you write an issue (Macro-ize unit test enhancement) and go ahead and put your changes in as a pull request to facilitate review? |
see #492 |
Fixed in #698 |
Describe the bug
Unit tests check the number of events sent during the test, many of these in sb_UT.c are reported as hex...Such as in Test_SB_Cmds_SendPrevSubs (line 2704.)
To Reproduce
Uncovered when I was changing GetPipeName to produce events (as part of making it a public API) and the unit test event counts had to be updated. A simple test is to change the "ExpRtn" for a test.
Expected behavior
Event counts should reported in decimal.
Code snips
See above.
System observed on:
Linux VM
Additional context
N/A
Reporter Info
[email protected]
The text was updated successfully, but these errors were encountered: