Commit graph

14145 commits

Author SHA1 Message Date
Richard Wheatley
777882d9b1 tests: drivers: rtc: rtc_api: boards: add conf file
Add configuration file to rtc_api

Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
2024-08-09 17:58:35 +01:00
Daniel Leung
2ef8c4e74f tests: debug/thread_analyzer: add some build tests
Add some build tests for thread_analyzer to catch build issues
at CI.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-08-09 17:58:03 +01:00
Yuval Peress
690134356c i2c_emul: Add support for CONFIG_I2C_TARGET_BUFFER_MODE
Add emulation and test to support the buffered target mode.

Signed-off-by: Yuval Peress <peress@google.com>
2024-08-09 08:40:51 -04:00
Yuval Peress
c394b2e6f8 test: Add i2c emulation for targets
Update i2c_emul.c to support i2c_target_register and i2c_target_unregister
function calls as well as support address forwarding in emulation.
Address forwarding helps us test IPCs in native sim. Instead of having to
emulate 2 separate cores, we can forward read/write requests from one bus
to another bus (effectively creating a loop). This way the same image can
simulate both the controller and the target.

Signed-off-by: Yuval Peress <peress@google.com>
2024-08-09 08:40:51 -04:00
Dmitrii Golovanov
889950843f tests: timer: behavior_external: fix MAX_STD_DEV
Fix `MAX_STD_DEV` calculation at the timer behavior external test.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-08-09 08:37:14 -04:00
Dmitrii Golovanov
d2ff869a1d tests: timer: behavior: fix MAX_STD_DEV recording
Fix misaligned name change for `MAX_STD_DEV` value.

Signed-off-by: Dmitrii Golovanov <dmitrii.golovanov@intel.com>
2024-08-09 08:37:14 -04:00
Furkan Akkiz
0b27b8437a tests: drivers: gpio: Enable gpio driver tests for max32666evkit board
Enable gpio driver test for MAX32666EVKIT

Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
2024-08-09 09:55:01 +02:00
Sadik Ozer
7475666ac9 tests: drivers: gpio: Enable gpio driver tests for max32666fthr board
Enable gpio driver test for max32666fthr

Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
2024-08-09 09:55:01 +02:00
Krzysztof Chruściński
70260720e9 tests: ipc: pbuf: Disable data cache management
Packet buffer is designed to run writer and reader code on two CPUs.
The write function cannot be preempted by the read function in a CPU,
or the cache management could result in data corruption. In the tests,
the reader and the writer are executed on a single CPU. Disable data
cache management to prevent potential data corruption.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
2024-08-09 09:54:29 +02:00
Chris Friedt
2aa31a3695 tests: posix: one tier0 platform per arch for integration tests
Add one tier0 platform per supported architecture.

Signed-off-by: Chris Friedt <cfriedt@tenstorrent.com>
2024-08-08 20:23:36 -04:00
Robert Lubos
d5fc86ed0a tests: net: mqtt: Make publisher/subscriber test suites self contained
The MQTT publisher/subscriber/pubsub tests suites are currently
depending on an external MQTT broker being available. In result, the
test suites cannot be executed in twister and need to be run manually,
which makes them kind of pointless from the CI perspective.

This commit reworks the tests, so that they no longer rely on an
external broker being available, but rather implement minimalistic
broker functionality for test purposes only. This will make the tests
self contained, and thus executable in the CI.

Since it makes not point to duplicate the effort between the test
suites, the test suites have been merged into a single mqtt_client test
suite.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-08-08 20:22:33 -04:00
Robert Lubos
71375d1414 tests: net: mqtt: Group existing MQTT 3.1.1 test suites
Currently existing tests suites verify MQTT 3.1.1 functionality,
therefore group them together under "mqtt/v3_1_1" directory, so
that the test base can be extended easily in the future with MQTT 5.0
tests without collision.

Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
2024-08-08 20:22:33 -04:00
Ricardo Rivera-Matos
a774cbc61a tests: build_all: Adds Haptics build test
Adds Haptics build test

Signed-off-by: Ricardo Rivera-Matos <rriveram@opensource.cirrus.com>
2024-08-08 15:57:12 +02:00
Flavio Ceolin
0205c7d511 pm: Remove deprecated symbol references
Do not reference PM_DEVICE_RUNTIME_EXCLUSIVE

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-08-08 15:38:04 +02:00
Anke Xiao
e69bfa5e7d tests: drivers: spi: add configuration for ke17z to test loopback
Add spi configurations of NXP frdm_ke17z and frdm_ke17z512 boards,
tested spi_loopback sample for lpspi drivers.
Update the "HAS_MCUX_*" kconfig to "DT_HAS_*" in testcase.yaml

Signed-off-by: Anke Xiao <anke.xiao@nxp.com>
2024-08-08 06:07:51 -04:00
Jonathan Rico
76ece09cb4 Bluetooth: Host: Add ISO HCI fragmentation test
Purpose is to verify we don't fragment ISO SDUs when they should fit the
controller's MTU.

Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
2024-08-08 06:07:08 -04:00
Manuel Argüelles
f89a2def84 tests: drivers: spi: remove overlay for mr_canhubk3
This overlay is no longer needed, as presently there are more test
scenarios covering all combinations of DMA and SPY_ASYNC support for
LPSPI peripheral.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-08-08 06:06:03 -04:00
Furkan Akkiz
2c703e7547 tests: drivers: gpio: Enable gpio driver tests for max32662evkit board
Enable gpio driver test for MAX32662EVKIT

Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
2024-08-07 19:04:26 -04:00
Benedikt Schmidt
d561b50695 tests: drivers: flash: stm32: add nucleo_f746zg
Add the nucleo_f746zg to the tests for the flash driver.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-08-07 19:02:49 -04:00
Yong Cong Sin
0787744684 tests: arch: common: stack_unwind: add qemu_riscv32e
qemu_riscv32e uses a different ISA and is kinda special, add it
to the testcase for better coverage.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
Signed-off-by: Yong Cong Sin <yongcong.sin@gmail.com>
2024-08-07 19:00:53 -04:00
Konrad Sikora
f3af39b4d7 drivers: sensor: Fix DHT20 build failure with CRC configured
Fixes the build error: 'crc' undeclared for
DHT20 sensor with CONFIG_DHT20_CRC option enabled.

Signed-off-by: Konrad Sikora <kontakt@konradsikora.pl>
2024-08-07 07:14:11 -04:00
Sadik Ozer
c07f8bab58 tests: drivers: gpio: Enable gpio driver tests for max32675 board
Enable gpio driver test for max32675evkit board

Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
2024-08-06 17:18:02 -04:00
Johann Fischer
5ddaa3b1a1 drivers: udc: add opaque pointer to store upper layer private data
Add an opaque pointer to store upper layer private data and initialize
it with the USB device context during controller initialization. Use the
pointer in event processing to get the correct context.

Fixes commit 48f2a4bc1a
("usb: device_next: remove initialized state checks in event processing")

Signed-off-by: Johann Fischer <johann.fischer@nordicsemi.no>
2024-08-06 17:17:41 -04:00
Tahsin Mutlugun
c83b91a0e4 tests: drivers: dma: Add MAX32680EVKIT overlay files
Enable 'chan_blen_transfer' and 'loop_transfer' tests for MAX32680EVKIT.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2024-08-06 17:16:35 -04:00
Furkan Akkiz
c2326ca55a tests: drivers: dma: Add MAX32672 boards overlay files
Enable 'chan_blen_transfer' and 'loop_transfer' tests for MAX32672 boards.

Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
2024-08-06 17:16:35 -04:00
Mert Ekren
481d4a472c tests: drivers: dma: Add MAX32670 overlay files
Enable 'chan_blen_transfer' and 'loop_transfer' tests for MAX32670EVKIT.

Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Mert Ekren <mert.ekren@analog.com>
2024-08-06 17:16:35 -04:00
Furkan Akkiz
185f328135 tests: drivers: dma: Add MAX32690 overlay files
Enable 'chan_blen_transfer' and 'loop_transfer' tests for MAX32690EVKIT.

Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Furkan Akkiz <hasanfurkan.akkiz@analog.com>
2024-08-06 17:16:35 -04:00
Sadik Ozer
3a7260dab3 tests: drivers: dma: Add MAX32655 board overlay files
Add MAX32655EVKIT and FTHR board overlay files to dma tests.

Co-authored-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
Co-authored-by: Maureen Helm <maureen.helm@analog.com>
Signed-off-by: Sadik Ozer <sadik.ozer@analog.com>
2024-08-06 17:16:35 -04:00
Richard Wheatley
f36bd0a075 tests: drivers: rtc: rtc_api: test_update_callback
Add skip for when no update callback is defined
in driver

Signed-off-by: Richard Wheatley <richard.wheatley@ambiq.com>
2024-08-06 17:14:39 -04:00
Gerard Marull-Paretas
b57481ab18 boards, tests: nrf54h20: add nordic,clock-enable property
Applies to:

- UART/E (TXD)
- SPIM (SCK, MOSI)
- SPIS (SCK, MISO)
- TWIM (SDA, SCL)

Except fast-instances.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-08-06 14:32:40 +02:00
Tahsin Mutlugun
11dc47da24 tests: i2c: i2c_target_api: Remove unneeded properties in I2C nodes
For commonly-accessible I2C nodes, status and pinctrl are now set in
board dts. Remove these properties from test overlay files.

Signed-off-by: Tahsin Mutlugun <Tahsin.Mutlugun@analog.com>
2024-08-06 09:19:42 +01:00
Katarzyna Giądła
8753534077 tests: subsys: storage: flash_map: Extend timeout storage.flash_map.mpu
The test `storage.flash_map.mpu` for `nrf52840dk/nrf52840` fails
althought the output is correct. Time to test execution is not enough.
This change extend test execution timeout.

Signed-off-by: Katarzyna Giądła <katarzyna.giadla@nordicsemi.no>
2024-08-06 09:17:20 +01:00
Guotao Zhang
28093cc4ef Bluetooth: tester: Increase the adv buf size to consider the extend adv
[Description]
Device hang is observed when LE Scan
[Root Cause]
For le_ext_adv_report, Data[i] of one adv report is 0-229,
for the adv_buf of saving, it just is 73 bytes, so sometimes
the bytes of adv report is more than the adv_buf, resulted hang
[Fix]
consider the le ext adv case.
[Testing]
After modified, Device hang is not observed after stress
testing with LE Scan

Signed-off-by: Guotao Zhang <guotao.zhang@nxp.com>
2024-08-05 16:29:36 +02:00
Grzegorz Chwierut
8e7cda75cc twister: pytest: Move helper methods to pyteste-harness package
Moved helper methods from tests/boot/with_mcumgr to pytest-harness
package. It can be reused by other tests.

Signed-off-by: Grzegorz Chwierut <grzegorz.chwierut@nordicsemi.no>
2024-08-05 16:29:13 +02:00
Torsten Rasmussen
e8e5169f95 cmake: remove the use of SOURCES in tests
Setting SOURCES before calling find_package() was deprecated in #51049.

Cleanup usage of SOURCES and instead use the proper target_sources()
CMake function.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2024-08-05 16:27:09 +02:00
Torsten Rasmussen
b939e720a6 tests: source Zephyr before project() call
Fixes: #73831

find_package(Zephyr) should be called before first project() call.

Zephyr package will test and force-set the correct toolchain, especially
the C compiler.
The project() will also set the C compiler, if not set already.

If project() is called first, then conflict arises on the C compiler
selection and thus the following message is seen:
> You have changed variables that require your cache to be deleted.
> Configure will be re-run and you may have to reset some variables.
> The following variables have changed:
> CMAKE_C_COMPILER= /usr/bin/gcc

This cache deletion results in other errors, such as a missing BOARD
setting.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2024-08-05 16:27:09 +02:00
Manuel Argüelles
67264e3fb9 boards: nxp: mr_canhubk3: enable STM counter
Enable the two available System Timer Module instances on this board.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-08-05 07:35:57 -05:00
Manuel Argüelles
896d8d6896 drivers: counter: nxp: convert STM to native driver
Convert NXP System Timer Module driver to a native driver.

Timer prescaler in tests is updated because short relative alarms
sometimes give false positives.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-08-05 07:35:57 -05:00
Yong Cong Sin
8e1ac56847 lib: posix: mutex: stubs remaining of _POSIX_THREAD_PRIO_PROTECT
Create stub functions for the remaining of
`_POSIX_THREAD_PRIO_PROTECT` option group.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-08-05 11:32:43 +02:00
Yong Cong Sin
0c4870a0f0 lib: posix: mutex: implement pthread_mutexattr_setprotocol
Implement and test `pthread_mutexattr_setprotocol()`.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-08-05 11:32:43 +02:00
Yong Cong Sin
50f47a44b7 lib: posix: mutex: check args of pthread_mutexattr_getprotocol
Perform arguments checking in the
`pthread_mutexattr_getprotocol()` function.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-08-05 11:32:43 +02:00
Bartlomiej Buczek
18ed02e643 tests: adc_api: add channel for nrf54 targets
add channel in overlay of nrf54 targets to increase test coverage.

Signed-off-by: Bartlomiej Buczek <bartlomiej.buczek@nordicsemi.no>
2024-08-05 11:32:23 +02:00
Yong Cong Sin
2ccfe8202d lib: posix: add stubs for thread-safe grp & pwd functions
Create stubs for getpwnam_r, getpwuid_r, getgrgid_r
& getgrnam_r.

These functions are in the _POSIX_THREAD_SAFE_FUNCTIONS
option group.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-08-05 10:17:27 +02:00
Yong Cong Sin
b7ad4c53b0 posix: fs: implement readdir_r
Add implementation for `readdir_r()`.

Signed-off-by: Yong Cong Sin <ycsin@meta.com>
2024-08-05 10:17:27 +02:00
Guru Mehar Rachaputi
f20ac87536 tests: bsim: set log level from command-line argument
Implementation to take command-line arguments to set log level in run
time for bsim module. Set default log level if no log level is passed
at runtime

Signed-off-by: Guru Mehar Rachaputi <gurumeharrachaputi@gmail.com>
2024-08-05 10:16:36 +02:00
Aleksandar Stanoev
52ffbd85c8 bluetooth: shell: Add shell commands for LE Connection Subrating
Add commands to allow requesting a subrate change via the BT shell.
A new build configuration has been added to ensure this is tested in CI.

Signed-off-by: Aleksandar Stanoev <aleksandar.stanoev@nordicsemi.no>
2024-08-05 10:16:27 +02:00
Manuel Argüelles
832261dbe5 boards: mr_canhubk3: enable SWT watchdog
Enable the Software Watchdog Timer instance on this board.

Now that SWT is enabled for this board and made the default watchdog,
sample.task_wdt.no_hw_fallback can be removed as is no longer needed.

Signed-off-by: Manuel Argüelles <manuel.arguelles@nxp.com>
2024-08-03 05:58:46 -05:00
Raffael Rostagno
fbd651e799 boards: esp32c6_devkitc: Test files for DMA and UART async, doc update
Test files for DMA and UART async. esp32c6_devkitc doc update

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-08-02 18:48:37 -05:00
Andrej Butok
36a1cacbe7 tests: flash: erase_blocks: Add README file
Add the brief README file for the erase_blocks test.
Every test/sample should have a readme file.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2024-08-02 18:41:23 -05:00
Pieter De Gendt
555a56f262 tests: kconfig: functions: Add min/max functions
Add test case for kconfig min/max functions.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-08-02 13:41:07 +02:00