-
Notifications
You must be signed in to change notification settings - Fork 6.9k
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
tests: posix: common: separate posix threads base into a standalone test #81339
Open
Pancakem
wants to merge
1
commit into
zephyrproject-rtos:main
Choose a base branch
from
DevHeadsCommunity:separate_posix_thread_base_test_into_standalone_test
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
tests: posix: common: separate posix threads base into a standalone test #81339
Pancakem
wants to merge
1
commit into
zephyrproject-rtos:main
from
DevHeadsCommunity:separate_posix_thread_base_test_into_standalone_test
+701
−91
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Pancakem
force-pushed
the
separate_posix_thread_base_test_into_standalone_test
branch
2 times, most recently
from
November 13, 2024 13:13
fcee92c
to
88d572c
Compare
15 tasks
cfriedt
changed the title
tests: posix: common: separate posix thread base into a standalone test
tests: posix: common: separate posix threads base into a standalone test
Nov 17, 2024
Pancakem
force-pushed
the
separate_posix_thread_base_test_into_standalone_test
branch
from
November 27, 2024 12:12
88d572c
to
4f4b818
Compare
cfriedt
requested changes
Nov 27, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please substitute
/posix_thread_base/posix_threads_base/g
Pancakem
force-pushed
the
separate_posix_thread_base_test_into_standalone_test
branch
3 times, most recently
from
December 2, 2024 17:17
831747c
to
4328024
Compare
cfriedt
requested changes
Dec 3, 2024
Comment on lines
449
to
542
ZTEST(pthread, test_pthread_set_get_concurrency) | ||
{ | ||
/* EINVAL if the value specified by new_level is negative */ | ||
zassert_equal(EINVAL, pthread_setconcurrency(-42)); | ||
|
||
/* | ||
* Note: the special value 0 indicates the implementation will | ||
* maintain the concurrency level at its own discretion. | ||
* | ||
* pthread_getconcurrency() should return a value of 0 on init. | ||
*/ | ||
zassert_equal(0, pthread_getconcurrency()); | ||
|
||
for (int i = 0; i <= CONFIG_MP_MAX_NUM_CPUS; ++i) { | ||
zassert_ok(pthread_setconcurrency(i)); | ||
/* verify parameter is saved */ | ||
zassert_equal(i, pthread_getconcurrency()); | ||
} | ||
|
||
/* EAGAIN if the a system resource to be exceeded */ | ||
zassert_equal(EAGAIN, pthread_setconcurrency(CONFIG_MP_MAX_NUM_CPUS + 1)); | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is part of the XSI_THREADS_EXT option group, so should not be modified in this PR
Pancakem
force-pushed
the
separate_posix_thread_base_test_into_standalone_test
branch
from
December 17, 2024 08:50
4328024
to
c3b8b4a
Compare
posix.common contains testsuites that can be separated into smaller groups of tests. This change moves pthread into a singular testsuite at tests/posix/thread_base app directory. Signed-off-by: Marvin Ouma <[email protected]>
Pancakem
force-pushed
the
separate_posix_thread_base_test_into_standalone_test
branch
from
December 17, 2024 09:28
c3b8b4a
to
01587a7
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #81491
posix.common contains testsuites that can be separated into smaller groups of tests. This change moves pthread, cond, key, mutex and mutex_attr into a singular testsuite at tests/posix/thread_base app directory.