Skip to content

Commit

Permalink
Partial nasa#1052, Select test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
jphickey committed Jun 4, 2021
1 parent 3a12bfb commit cdcce73
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/unit-tests/oscore-test/ut_oscore_select_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,11 @@ void UT_os_select_fd_test(void)
UT_RETVAL(OS_SelectFdIsSet(NULL, selecttest_fd), false);

UT_RETVAL(OS_SelectFdAdd(&FdSet, invalid_fd), OS_ERR_INVALID_ID);
UT_RETVAL(OS_SelectFdAdd(&FdSet, OS_OBJECT_ID_UNDEFINED), OS_ERR_INVALID_ID);
UT_RETVAL(OS_SelectFdClear(&FdSet, invalid_fd), OS_ERR_INVALID_ID);
UT_RETVAL(OS_SelectFdClear(&FdSet, OS_OBJECT_ID_UNDEFINED), OS_ERR_INVALID_ID);
UT_RETVAL(OS_SelectFdIsSet(&FdSet, invalid_fd), false);
UT_RETVAL(OS_SelectFdIsSet(&FdSet, OS_OBJECT_ID_UNDEFINED), false);

UT_NOMINAL(OS_SelectFdZero(&FdSet));
UT_NOMINAL(OS_SelectFdAdd(&FdSet, selecttest_fd));
Expand Down Expand Up @@ -147,6 +150,7 @@ void UT_os_select_single_test(void)
(unsigned int)StateFlags);

UT_RETVAL(OS_SelectSingle(invalid_fd, &StateFlags, 0), OS_ERR_INVALID_ID);
UT_RETVAL(OS_SelectSingle(OS_OBJECT_ID_UNDEFINED, &StateFlags, 0), OS_ERR_INVALID_ID);
}

/*--------------------------------------------------------------------------------*
Expand Down

0 comments on commit cdcce73

Please sign in to comment.