utils-lists 4.0.0
µOS++ C++ intrusive lists utilities
|
The µOS++ testing strategy is to compile the sources with as many toolchains as possible, and run them on as many platforms as possible.
The supported test platforms are:
platform-native
- run the test applications as native processes on the development machineplatform-qemu-cortex-m0
- run the tests as fully semihosted Cortex-M0 applications on a QEMU mps2-an385 emulated board (an Arm Cortex-M3 development board)platform-qemu-cortex-m3
- run the tests as fully semihosted Cortex-M3 applications on a QEMU mps2-an385 emulated board (an Arm Cortex-M3 development board)platform-qemu-cortex-m4f
- run the tests as fully semihosted Cortex-M4 applications on a QEMU mps2-an386 emulated board (an Arm Cortex-M4 development board)platform-qemu-cortex-m7f
- run the tests as fully semihosted Cortex-M7 applications on a QEMU mps2-an500 emulated board (an Arm Cortex-M7 development board)platform-qemu-cortex-a15
- run the tests as fully semihosted Cortex-A15 applications on a QEMU virt emulated boardplatform-qemu-cortex-a72
- run the tests as fully semihosted Cortex-A72 (64-bit) applications on a QEMU virt emulated boardplatform-qemu-riscv-rv32imac
- run the tests as fully semihosted RISC-V RV32IMAC applications on a QEMU virt emulated boardplatform-qemu-riscv-rv64imafdc
- run the tests as fully semihosted RISC-V RV32IMAFDC applications on a QEMU virt emulated boardThe tests are built and executed on:
The build configurations use exactly the same source files on all platforms, without changes. On embedded platforms, the applications interact with the host via the Arm semihosting mechanism.
To improve source code portability, the builds are repeated with multiple toolchains, even with multiple versions of the same toolchain.
The following toolchains are used:
The sample-test.cpp file is a simple application to demonstrate how to call the few primitives available in the library.
A typical run looks like:
The unit-test.cpp file is an exhaustive test trying to validate that all the library functions work as expected. It uses the µTest++ framework.
A typical run looks like:
There is a GitHub Actions CI workflow that runs a selection of the tests on every push; for details see ci.yml.
A second workflow can be triggered manually before releases, and runs all available tests on all supported platforms; for details see test-all.yml
micro-os-plus
GitHub organisation to be up and running.The tests can be executed manually on any of the supported platforms:
build-essential
)A recent Node.js (>=16) run environment. For instructions on how to install it, see the prerequisites page.
With npm available, install xpm:
To clone the development branch (xpack-develop
), run the following commands in a terminal (on Windows use the Git Bash console):
There are multiple predefined actions, to run various selections of tests, from a single run with the system compiler, to all possible tests.
To run the tests with the system compiler:
To run a selection of tests with the latest versions of the toolchains:
To run all tests with the latest versions of the toolchains:
To run all tests with all toolchain versions:
The native clang13 and clang14 tests fail on Arch & derivates machines, with an error related to a missing symbol in libunwind.
The issue is caused by older clang releases returning the paths in -print-search-dirs
in a wrong order, which results in including the wrong library from the system instead of the toolchain library.
To do a deep cleanup in order to free space or to restart the tests from scratch:
~/.local/xPacks
and ~/.cache/xpacks
on GNU/Linux,~/Library/xPacks
and ~/Library/Caches/xPacks
on macOS,%APPDATA%\xPacks
and %LOCALAPPDATA%\Caches\xPacks
on Windows.