The peridiodical wdog test cases should be removed after removing of the periodical wdog APIs.
Signed-off-by: ouyangxiangzhen <ouyangxiangzhen@xiaomi.com>
- Add another signal action, "interfere_action", and signal the interfere thread
- In both signal action functions (waiter and interfere), check that they get executed
in correct thread's context
Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
"kill" sends the signal to all the the threads in the group. The intention of
the test is to send signals only to the "waiter" thread.
Running signal actions in parallel is not compatible behaviour with
the signest test, which assumes that signals are being run one after another.
For example running signals 38 and 40 in parallel on two threads/two cpus
would cause the test incorrectly fail on "even signals nested".
Signed-off-by: Jukka Laitinen <jukka.laitinen@tii.ae>
remove empty strings from FetchContent to eliminate cmake build warnings like this:
CMake Warning (dev) at /usr/share/cmake/Modules/FetchContent.cmake:1564 (cmake_parse_arguments):
The BUILD_COMMAND keyword was followed by an empty string or no value at
all. Policy CMP0174 is not set, so cmake_parse_arguments() will unset the
ARG_BUILD_COMMAND variable rather than setting it to an empty string.
Signed-off-by: raiden00pl <raiden00@railab.me>
1.Some test functions are named too simply
2.Many driver tests depend on specific configurations and hardware, and the unified specification name facilitates cmocka to skip tests by using the skip parameter for wildcard matching
Signed-off-by: zhangshoukui <zhangshoukui@xiaomi.com>
https://github.com/apache/nuttx/blob/master/tools/ci/testrun/script/test_framework/test_cmocka.py
cmocka --skip test_case_posix_timer|test_case_oneshot|write_default|read_default|burst_test|gpiotest01
In the CI of the community, this test is skipped because this test will block the terminal, and I think that the test added to cmocka should not be designed this way
Signed-off-by: zhangshoukui <zhangshoukui@xiaomi.com>
Add a new test for moving mutexes to verify behavior when a mutex is relocated.
* Introduced mutex_thread_args_t structure for thread arguments
* Created moved_mutex_thread_func to handle mutex operations in threads
* Updated mutex_test to include mutex_move_test for comprehensive testing
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
Summary:
In the case of slow overall system response (such as when MM_KASAN is turned on), the nxevent case work thread will not be executed and will be switched back to the main thread, so that the event does not get the expected result and the case fails.
By adjusting the thread priority, the work thread can be scheduled to avoid the expected result failure
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>
In the previous changes to the apps/testing folder, I added an extra slash in the make.defs of uclibcxx, atomic.
Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com>
This application test the libc's `wcstombs` function for different
len sizes (bigger than the converted string, exactly the size of
it and smaller than it).
1.rename original mm folder to heaptest and move it to mm folder
2.move the following folders into the new mm folder:
cachetest, heaptest, iob, kasantest, memstress, memtester, ramtest, stressapptest
Signed-off-by: tengshuangshuang <tengshuangshuang@xiaomi.com>
cmocka_driver_gpio //gpio input/output is tested by default
cmocka_driver_gpio -a /dev/gpio0 -b /dev/gpio1 -l // test loop
cmocka_driver_gpio -a /dev/gpio0 -b /dev/gpio0 // gpio input/output is tested by default
Signed-off-by: zhangshoukui <zhangshoukui@xiaomi.com>
==1805058==ERROR: AddressSanitizer: heap-use-after-free on address 0xe18126a0 at pc 0x52b06320 bp 0xd7b13ee8 sp 0xd7b13ed8
READ of size 1 at 0xe18126a0 thread T0
#0 0x52b0631f in tre_parse regex/regcomp.c:1356
#1 0x52b2b1d0 in regcomp regex/regcomp.c:3710
#2 0x48f55435 in c_regexmatch cmocka/src/cmocka.c:494
#3 0x48f65bcf in _cmocka_run_group_tests cmocka/src/cmocka.c:3252
#4 0x48f67e2d in cmocka_fs_test_main apps/testing/testsuites/kernel/fs/cmocka_fs_test.c:201
#5 0x46210b2a in nxtask_startup sched/task_startup.c:72
#6 0x45ff40fb in nxtask_start task/task_start.c:116
#7 0x462695bb in pre_start sim/sim_initialstate.c:52
Signed-off-by: zhangshoukui <zhangshoukui@xiaomi.com>
Based on the original directory structure, an additional utils directory is added. It store public functions which used by multiple testcases, such as the tcp server-related functions added this time. In addition, two testcases for testing tcp connections have been added.
Signed-off-by: zhangshuai39 <zhangshuai39@xiaomi.com>
Clean up code by removing redundant and unused header file includes that were identified through static analysis.
This improves code readability and reduces unnecessary dependencies.
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
Provides a network automated testing framework, including the main directory structure and Makefile, CMakeLists, Kconfig and other files such as tcp.
Signed-off-by: zhangshuai39 <zhangshuai39@xiaomi.com>
After thread A holds the semaphore, it first accesses it safely. After releasing it, thread B closes MTE for unsafe access. After accessing, it switches back to thread A for unsafe access. At this time, an error should be reported.
log:
Process 1 holding lock
Process 2 holding lock
Process 1 holding lock again
default_fatal_handler: (IFSC/DFSC) for Data/Instruction aborts: synchronous tag check fault
arm64_exception_handler: CurrentEL: MODE_EL1
arm64_exception_handler: ESR_ELn: 0x96000011
arm64_exception_handler: FAR_ELn: 0xf00000040441700
arm64_exception_handler: ELR_ELn: 0x402ee5f4
print_ec_cause: DABT (current EL)
print_ec_cause: Data Abort taken without a change in Exception level
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
apps/testing/nand_sim/nand_sim_main.c:172:(.text.nand_main+0x93): undefined reference to `nand_ram_initialize'
collect2: error: ld returned 1 exit status
Signed-off-by: zhangshoukui <zhangshoukui@xiaomi.com>
Summary:
"",
instead of
" ",
to the first argument.
Test #29 returned 0 instead of 1.
Test #29 assigned
"",
instead of
" q",
to the first argument.
Test #30 returned 0 instead of 2.
Test #30 assigned
"",
instead of
" ",
to the first argument.
Test #30 assigned
"",
instead of
"Q",
to the second argument.
Test #31 returned 0 instead of 2.
Test #31 assigned
"",
instead of
"qwerty-",
to the first argument.
Test #31 assigned
"",
instead of
"QWERTY-",
to the second argument.
Signed-off-by: chenrun1 <chenrun1@xiaomi.com>