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

Test_OS_ConvertToArrayIndex: tautological assertion #425

Closed
lethuillierg opened this issue Apr 18, 2020 · 2 comments · Fixed by #428
Closed

Test_OS_ConvertToArrayIndex: tautological assertion #425

lethuillierg opened this issue Apr 18, 2020 · 2 comments · Fixed by #428
Assignees
Labels
bug unit-test Tickets related to the OSAL unit testing (functional and/or coverage)
Milestone

Comments

@lethuillierg
Copy link

lethuillierg commented Apr 18, 2020

Describe the bug
Unit test Test_OS_ConvertToArrayIndex implements the following assertion:

UtAssert_True(local_idx1 == local_idx1, "local_idx1 (%lu) == local_idx2 (%lu)",
(unsigned long)local_idx1, (unsigned long)local_idx2);

This is a tautological assertion as it compares local_idx1 with itself.

To Reproduce
N/A (code analysis)

Expected behavior
local_idx1 should be compared with local_idx2:

UtAssert_True(local_idx1 == local_idx2, "local_idx1 (%lu) == local_idx2 (%lu)",
            (unsigned long)local_idx1, (unsigned long)local_idx2);

Code snips
See above.

System observed on:
N/A (code analysis)

Additional context
N/A

Reporter Info
Guillaume Lethuillier - Personal

@skliper skliper added the bug label Apr 20, 2020
@skliper skliper added this to the 5.1.0 milestone Apr 20, 2020
@skliper
Copy link
Contributor

skliper commented Apr 20, 2020

@yammajamma - want to take this one?

@skliper skliper added the unit-test Tickets related to the OSAL unit testing (functional and/or coverage) label Apr 20, 2020
@yammajamma
Copy link
Contributor

yammajamma commented Apr 20, 2020

@skliper Yes, I can take this one.

astrogeco added a commit that referenced this issue Apr 28, 2020
…n-Fix

Fix #425, Correct Test_OS_ConvertToArrayIndex assertion typo
jphickey pushed a commit to jphickey/osal that referenced this issue Aug 10, 2022
jphickey pushed a commit to jphickey/osal that referenced this issue Aug 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug unit-test Tickets related to the OSAL unit testing (functional and/or coverage)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants