diff options
| author | Tom Rini <[email protected]> | 2025-11-24 09:34:29 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-11-24 09:34:29 -0600 |
| commit | 4a4871e3dc38f3f771d2713b805e79e6191b4297 (patch) | |
| tree | f3cbb63c259f8cce92e87bf1a30b69c02b07c2dc /doc/develop | |
| parent | 6e7d2399c8139f8e2d037e446236b8d8bdbca604 (diff) | |
| parent | c5e6d2ab7eba68cbfb600cdc131c0c375ced2ec9 (diff) | |
Merge tag 'v2026.01-rc3' into next
Prepare v2026.01-rc3
Diffstat (limited to 'doc/develop')
| -rw-r--r-- | doc/develop/pytest/usage.rst | 23 | ||||
| -rw-r--r-- | doc/develop/release_cycle.rst | 4 | ||||
| -rw-r--r-- | doc/develop/tests_writing.rst | 63 |
3 files changed, 53 insertions, 37 deletions
diff --git a/doc/develop/pytest/usage.rst b/doc/develop/pytest/usage.rst index 596b0397379..7335a39b963 100644 --- a/doc/develop/pytest/usage.rst +++ b/doc/develop/pytest/usage.rst @@ -35,21 +35,26 @@ can be installed via the command pip install -r requirements.txt In order to execute certain tests on their supported platforms other tools -will be required. The following is an incomplete list: +will be required. The following packages may be needed: -* gdisk -* dfu-util -* dtc -* openssl -* e2fsprogs -* util-linux +* cgpt * coreutils +* device-tree-compiler +* dfu-util * dosfstools +* e2fsprogs * efitools +* fdisk +* gdisk +* libgnutls28-dev / gnutls-devel * mount * mtools +* openssl * sbsigntool +* swig * udisks2 +* util-linux +* vboot-kernel-utils / vboot-utils Please use the appropriate commands for your distribution to match these tools up with the package that provides them. @@ -63,7 +68,7 @@ The test script supports either: Further details are described later. The usage of the command ``sudo`` is not allowed in tests. Using elevated -priviledges can lead to security concerns. Furthermore not all users may have +privileges can lead to security concerns. Furthermore not all users may have administrator rights. Therefore the command ``sudo`` must not be used in tests. To create disk images we have helper functions located in ``test/py/tests/fs_helper.py`` which shall be used in any tests that require @@ -387,7 +392,7 @@ to flash, pulsing the board's reset signal is likely all this script needs to do. However, in some scenarios, this script may perform other actions. For example, it may call out to some SoC- or board-specific vendor utility in order to download the U-Boot binary directly into RAM and execute it. This would -avoid the need for ``u-boot-test-flash1`` to actually write U-Boot to flash, +avoid the need for ``u-boot-test-flash`` to actually write U-Boot to flash, thus saving wear on the flash chip(s). u-boot-test-release diff --git a/doc/develop/release_cycle.rst b/doc/develop/release_cycle.rst index 8b0a0333863..56cbfcb4b65 100644 --- a/doc/develop/release_cycle.rst +++ b/doc/develop/release_cycle.rst @@ -69,13 +69,13 @@ Future Releases .. The following commented out dates are for when release candidates are planned to be tagged. -For the next scheduled release, release candidates were made on:: +For the next scheduled release, release candidates were made on: * U-Boot |next_ver|-rc1 was released on Mon 27 October 2025. * U-Boot |next_ver|-rc2 was released on Mon 10 November 2025. -.. * U-Boot |next_ver|-rc3 was released on Mon 24 November 2025. +* U-Boot |next_ver|-rc3 was released on Mon 24 November 2025. .. * U-Boot |next_ver|-rc4 was released on Mon 08 December 2025. diff --git a/doc/develop/tests_writing.rst b/doc/develop/tests_writing.rst index 062194659b5..1a020caa411 100644 --- a/doc/develop/tests_writing.rst +++ b/doc/develop/tests_writing.rst @@ -206,8 +206,44 @@ some common test tasks. (there are also UEFI C tests in lib/efi_selftest/ not considered here.) +Add a C test to an existing suite +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +Use this when you are adding to or modifying an existing feature outside driver +model. An example is bloblist. + +Add a new function in the same file as the rest of the suite and register it +with the suite. For example, to add a new mem_search test:: + + /* Test 'ms' command with 32-bit values */ + static int mem_test_ms_new_thing(struct unit_test_state *uts) + { + /* test code here */ + + return 0; + } + MEM_TEST(mem_test_ms_new_thing, UTF_CONSOLE); + +Note that the MEM_TEST() macros is defined at the top of the file. + +Example commit: 9fe064646d2 ("bloblist: Support relocating to a larger space") [1] + +* A successful test returns 0. +* A skipped test returns -EAGAIN. +* Any other value signals a failure. + +Include ``test/ut.h`` defines a number of macros to check values and to return +from the test function if the assertion fails. See :doc:`../api/test` +for details. + +[1] https://gitlab.denx.de/u-boot/u-boot/-/commit/9fe064646d2 + + Add a new driver model test -~~~~~~~~~~~~~~~~~~~~~~~~~~~ +''''''''''''''''''''''''''' + +``dm`` is the test suite that contains C tests for U-boot +:doc:`Driver Model <driver-model/index>`. Use this when adding a test for a new or existing uclass, adding new operations or features to a uclass, adding new ofnode or dev_read_() functions, or anything @@ -249,31 +285,6 @@ Example commit: c48cb7ebfb4 ("sandbox: add ADC unit tests") [1] [1] https://gitlab.denx.de/u-boot/u-boot/-/commit/c48cb7ebfb4 -Add a C test to an existing suite -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -Use this when you are adding to or modifying an existing feature outside driver -model. An example is bloblist. - -Add a new function in the same file as the rest of the suite and register it -with the suite. For example, to add a new mem_search test:: - - /* Test 'ms' command with 32-bit values */ - static int mem_test_ms_new_thing(struct unit_test_state *uts) - { - /* test code here */ - - return 0; - } - MEM_TEST(mem_test_ms_new_thing, UTF_CONSOLE); - -Note that the MEM_TEST() macros is defined at the top of the file. - -Example commit: 9fe064646d2 ("bloblist: Support relocating to a larger space") [1] - -[1] https://gitlab.denx.de/u-boot/u-boot/-/commit/9fe064646d2 - - Add a new test suite ~~~~~~~~~~~~~~~~~~~~ |
