In the current pipe_api test file we inadvertantly use VLA.
Toolchains are allowed by standard to allocate VLA on
heap for example. Therefore in my opinion we shouldn't
use VLA atleast in kernel+kernel tests.
Signed-off-by: Robin Kastberg <robin.kastberg@iar.com>
Tests use nordic specific comparator api which enable it's
runtime reconfiguration.
As there were no tests prepared when introducing this api,
PR adds some to extend test coverage.
Signed-off-by: Bartlomiej Buczek <bartlomiej.buczek@nordicsemi.no>
Update the Central and Peripheral GATT write command sample
to measure throughput across all supported connection PHYs.
Cover the sample in BabbleSIM CI testing to validate the 2M
PHY throughput after all supported PHYs have been changed
once.
Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Building kernel.threads.apis with clang warns:
tests/kernel/threads/thread_apis/src/main.c:362:6: error: variable 'ret'
is used uninitialized whenever 'if' condition is true
[-Werror,-Wsometimes-uninitialized]
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:380:6: note: uninitialized
use occurs here
if (ret != 0) {
^~~
tests/kernel/threads/thread_apis/src/main.c:362:2: note: remove the 'if'
if its condition is always false
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:362:6: error: variable 'ret'
is used uninitialized whenever '||' condition is true
[-Werror,-Wsometimes-uninitialized]
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:380:6: note: uninitialized
use occurs here
if (ret != 0) {
^~~
tests/kernel/threads/thread_apis/src/main.c:362:6: note: remove the '||'
if its condition is always false
if (m == ISR_ALREADY_EXIT || m == ISR_RUNNING) {
^~~~~~~~~~~~~~~~~~~~~~~~
tests/kernel/threads/thread_apis/src/main.c:329:9: note: initialize the
variable 'ret' to silence this warning
int ret;
^
= 0
Signed-off-by: Tom Hughes <tomhughes@chromium.org>
Changes the type of both the tm_message_sent and tm_message_received
arrays from 'unsigned long' to 'unsigned int'. The test expects those
arrays to be 16 bytes long. This was a problem on 64-bit platforms
as 'unsigned long' is 8 bytes, which made the arrays 32 bytes long.
On both our supported 32-bit and 64-bit platforms, 'unsigned int'
works out to be 4 bytes long, thereby giving us the requisite 16
byte buffer.
Although a case could be made for using 'uint32_t', this was not
chosen simply to keep the structure as close as practical to the
original thread_metric implementation.
Fixes#83864
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
The update callback remains enabled after the test finishes, leaving the
RTC in a modified state. This change ensures the callback is properly
disabled, restoring the RTC to its original condition.
Signed-off-by: Måns Ansgariusson <Mansgariusson@gmail.com>
Include the Epson RX8130CE RTC driver in the RTC build tests to ensure it
compiles correctly and remains free of build regressions.
Signed-off-by: Måns Ansgariusson <Mansgariusson@gmail.com>
posix.common contains testsuites that can be separated into smaller
groups of tests. This change moves mqueue into a singular
testsuite at tests/posix/message_passing app directory.
Signed-off-by: Marvin Ouma <pancakesdeath@protonmail.com>
The intention of the test is to have a meta-IRQ preempt a cooperative
thread, then ensure the same cooperative thread is resumed back to instead
of a higher priority thread. Thus, the test needs to assert that the lower
priority cooperative thread is not yet complete when it makes the higher
priority thread ready to run.
This change reveals bugs like #80574, where the meta-IRQ is unable to
preempt a cooperative thread.
Signed-off-by: Kalle Kietäväinen <kalle.kietavainen@silabs.com>
In the usbd_register_all_classes(), we may need to skip some instances
as they may have very specific function like USB DFU "DFU mode" which
should not be available by default.
Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
After recent kernel changes there's some thread scheduling race when
running tests, therefore add k_yield() at the end of the test to make
sure the network stack has a chance to run in between tests.
Make sure CONFIG_NET_TCP_TIME_WAIT_DELAY is set to 0 so that TCP
connections are released immediately.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
After recent kernel changes there's some thread scheduling race when
running tests, therefore add k_yield() at the end of each test to make
sure the server thread has a chance to run and do the cleanup.
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Add test support for Counter driver of RZ/G3S-SMARC
Signed-off-by: Hieu Nguyen <hieu.nguyen.ym@bp.renesas.com>
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
Add overlays for xg24_dk2601b and xg27_dk2602a for the accuracy test.
Update the api test to use named macros for readability.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
Test was staring a TX transfer and aborting it after 300 us from
the timer handler. Test was assuming that ongoing transfer will
not finish in those 300 us. This might not be true for higher
baudrates. Instead of using fixed timeout, a value is calculated
from the baudrate and targets to abort the transfer after approx.
20 bytes of 95 byte long transfer.
Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
Add build test configurations for the silabs_acmp comparator. Enable this
build testing on all series 2 silabs boards that currently support the
comparator driver.
Signed-off-by: Christian Galante <christian.galante@silabs.com>
Add board overlays to execute the comparator gpio_loopback testsuite on
xg24_dk2601b and xg29_rb4412a. The testsuite was executed and was seen
to pass on both boards locally with twister.
Signed-off-by: Christian Galante <christian.galante@silabs.com>
the adc0 node is now disabled by default in the soc
enable it so that adc test passes for this board
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Make sure the tests work if VLAN count is set to 0. This means
that only priority tagged (tag 0) VLAN frames can be received.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
nRF70 can only choose a single security method due to limiting memory,
so, add individual tests to ensure build.
This is based on tests/net/wifi/configs test.
Signed-off-by: Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Keep on testing the function but fix logic where applicable
and remove last_erased_page_start_offset which has been replaced
with erased_up_to in stream_flash_ctx.
Signed-off-by: Dominik Ermel <dominik.ermel@nordicsemi.no>
Add tests to the YAML suite for generator expressions. The test checks
that generator expressions are handled as expected at different stages:
- immediately after yaml_save(), the file must contain only non-genex
entries;
- at a later time, after the target has been built, the file must
contain all the expanded genex values.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
To verify proper functionality, the YAML module test suite is now run
twice: once in the regular CMake project mode and once in the CMake
script mode.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
This introductory commit removes the ignored 'actual' variable from the
'yaml_set()' calls in the tests to make the code cleaner. Also, a badly
indented block is fixed in the 'message()' macro.
No functional change is introduced by this commit.
Signed-off-by: Luca Burelli <l.burelli@arduino.cc>
Make sure that buffer configuration and buffer lengths provided in
struct msghdr are left intact after being processed by recvmsg().
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
Make sure that buffer configuration and buffer lengths provided in
struct msghdr are left intact after being processed by recvmsg().
Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
The goal of this test is to ensure that setting the device name by
writing to the GAP 'Device Name' characteristic work as expected.
Signed-off-by: Théo Battrel <theo.battrel@nordicsemi.no>