Skip to content
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

CFE_SB_TimeStampMsg in ut_sb_stubs.c does not record MsgPtr argument value #747

Closed
asgibson opened this issue Jun 17, 2020 · 0 comments · Fixed by #748 or #765
Closed

CFE_SB_TimeStampMsg in ut_sb_stubs.c does not record MsgPtr argument value #747

asgibson opened this issue Jun 17, 2020 · 0 comments · Fixed by #748 or #765

Comments

@asgibson
Copy link
Contributor

asgibson commented Jun 17, 2020

Describe the bug
The value passed into CFE_SB_TimeStampMsg cannot be checked because the context value is not put into the UT_Stub_CopyFromLocal function.

To Reproduce
Write a unit test that attempts to check this value by setting up UT_SetDataBuffer.
Test fails because the value was never saved so it will not equal the expected value.

Expected behavior
UT_SetDataBuffer when used for CFE_SB_TimeStampMsg will copy the argument value from local (UT_Stub_CopyFromLocal).

Code snips
Current code:

void CFE_SB_TimeStampMsg(CFE_SB_MsgPtr_t MsgPtr)
{
    UT_DEFAULT_IMPL(CFE_SB_TimeStampMsg);
}

System observed on:

  • Hardware : PC
  • OS: RHEL7 - 3.10.0-1062.1.2.el7.x86_64
  • Versions cFE 6.7

Additional context
Add any other context about the problem here.

Reporter Info
Full name and company/organization if applicable

astrogeco added a commit that referenced this issue Jul 1, 2020
Fix #747, Update CFE_SB_TimeStampMsg to save the message pointer argument
astrogeco pushed a commit that referenced this issue Jul 1, 2020
In ut_sb_stubs.c, update CFE_SB_TimeStampMsg  to save the message
pointer argument with UT_Stub_CopyFromLocal so that unit tests can check
it
astrogeco pushed a commit that referenced this issue Jul 26, 2020
In ut_sb_stubs.c, update CFE_SB_TimeStampMsg  to save the message
pointer argument with UT_Stub_CopyFromLocal so that unit tests can check
it
@skliper skliper added this to the 6.8.0 milestone Sep 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants