All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 00/11] Move test/py image creation into separate modules
@ 2026-05-23  8:54 Simon Glass
  2026-05-23  8:54 ` [PATCH v2 01/11] test: Create a common file for image utilities Simon Glass
                   ` (11 more replies)
  0 siblings, 12 replies; 24+ messages in thread
From: Simon Glass @ 2026-05-23  8:54 UTC (permalink / raw)
  To: u-boot
  Cc: Simon Glass, Heinrich Schuchardt, Jaehoon Chung, Jerome Forissier,
	Kory Maincent, Kuan-Wei Chiu, Marek Vasut, Marek Vasut,
	Marek Vasut, Martin Schwan, Mattijs Korpershoek, Neil Armstrong,
	Peng Fan, Philip Molloy, Quentin Schulz, Raymond Mao,
	Stefan Roese, Tom Rini, Yao Zi

test_ut.py has accumulated a setup_*_image() helper for each image that
the bootflow tests want to boot. Each one is mostly shell script and
partition layout, so the file is large and the test logic is hidden
among image-creation details.

Move each setup function to its own module under test/py/img/, with a
shared common.py for mkdir_cond(), copy_partition() and the
make_extlinux_disk() helper. Each patch moves one image at a time so
reviewers can see the relocation cleanly. The modules are named after
the bootmeth or feature they exercise rather than the distribution they
are modelled on.

While here, also redirect the generated disk images to the
persistent-data directory instead of writing them under the source
tree. The sandbox mmc, scsi and usb-flash drivers now look there first.

Further improvements are planned, such as using the context manager
when creating partitions.

Changes in v2:
- Rename the setup_extlinux_image() helper to make_extlinux_disk()
- Rename the module to extlinux and the function to
  setup_extlinux_image(), naming it after the bootmeth it tests rather
  than the Fedora distribution it is modelled on
- Rename the module to script and the function to setup_script_image(),
  naming it after the bootmeth it tests rather than the Armbian
  distribution it is modelled on
- Reword to drop the per-OS naming, since the modules are now named
  after the bootmeth or feature they test

Simon Glass (11):
  test: Create a common file for image utilities
  test: Move extlinux image-creation to its own file
  test: Move script image-creation to its own file
  test: Move ChromeOS image-creation to its own file
  test: Move Android image-creation to its own file
  test: Move EFI image-creation to its own file
  test: Move the configuration-editor setup to its own file
  test: Add Args docstrings to img setup functions
  test: Reformat line wraps in img setup functions
  sandbox: Find disk images in the persistent-data directory
  test: Move disk images to persistent-data directory

 MAINTAINERS                      |   5 +
 drivers/mmc/sandbox_mmc.c        |  13 +-
 drivers/scsi/sandbox_scsi.c      |  15 +-
 drivers/usb/emul/sandbox_flash.c |  14 +-
 test/py/img/android.py           | 143 ++++++++
 test/py/img/cedit.py             |  24 ++
 test/py/img/chromeos.py          | 153 +++++++++
 test/py/img/common.py            |  86 +++++
 test/py/img/efi.py               |  37 +++
 test/py/img/extlinux.py          |  36 ++
 test/py/img/script.py            | 132 ++++++++
 test/py/tests/test_ut.py         | 541 +------------------------------
 12 files changed, 666 insertions(+), 533 deletions(-)
 create mode 100644 test/py/img/android.py
 create mode 100644 test/py/img/cedit.py
 create mode 100644 test/py/img/chromeos.py
 create mode 100644 test/py/img/common.py
 create mode 100644 test/py/img/efi.py
 create mode 100644 test/py/img/extlinux.py
 create mode 100644 test/py/img/script.py

---
base-commit: bacf09599a133f0274bc9fb8e67bfb444f057c16
branch: testc-us2

-- 
2.43.0


^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2026-06-08  8:50 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-23  8:54 [PATCH v2 00/11] Move test/py image creation into separate modules Simon Glass
2026-05-23  8:54 ` [PATCH v2 01/11] test: Create a common file for image utilities Simon Glass
2026-06-08  8:04   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 02/11] test: Move extlinux image-creation to its own file Simon Glass
2026-06-08  8:17   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 03/11] test: Move script " Simon Glass
2026-06-08  8:13   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 04/11] test: Move ChromeOS " Simon Glass
2026-06-08  8:19   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 05/11] test: Move Android " Simon Glass
2026-06-08  8:21   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 06/11] test: Move EFI " Simon Glass
2026-06-08  8:22   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 07/11] test: Move the configuration-editor setup " Simon Glass
2026-06-08  8:23   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 08/11] test: Add Args docstrings to img setup functions Simon Glass
2026-06-08  8:24   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 09/11] test: Reformat line wraps in " Simon Glass
2026-06-08  8:27   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 10/11] sandbox: Find disk images in the persistent-data directory Simon Glass
2026-06-08  8:41   ` Mattijs Korpershoek
2026-05-23  8:54 ` [PATCH v2 11/11] test: Move disk images to " Simon Glass
2026-06-08  8:49   ` Mattijs Korpershoek
2026-06-08  7:53 ` [PATCH v2 00/11] Move test/py image creation into separate modules Mattijs Korpershoek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.