Skip to content

Commit

Permalink
tests: posix: separate suite for pthread_t and pthread_attr_t
Browse files Browse the repository at this point in the history
In order to make state more manageable among the other
posix api tests, create a separate ZTEST_SUITE() called pthread
and another ZTEST_SUITE() called pthread_attr.

The tests in the pthread suite mainly operate on the pthread_t
type, while tests in the pthread_attr suite mainly operate on
the pthread_attr_t type.

The pthread_attr testsuite is moved to a separate file
(pthread_attr.c).

Having separate test suites allows us to narrow the scope of
the tests and have a better degree of control over the state.

Some effort went in to highlighting undefined behaviour at the
API level. This was quite intentional, as we will need to be
be able to test / verify that we do in fact have deterministic
outcomes when users attempt operations that result in undefined
behaviour (e.g. assert).

Signed-off-by: Christopher Friedt <[email protected]>
  • Loading branch information
cfriedt committed Jan 16, 2024
1 parent a2a3140 commit 9074fea
Show file tree
Hide file tree
Showing 2 changed files with 656 additions and 542 deletions.
Loading

0 comments on commit 9074fea

Please sign in to comment.