mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH 0/4] test: add/document pytest --graphic, --env, --fs
@ 2025-07-08 19:35 Ahmad Fatoum
  2025-07-08 19:35 ` [PATCH 1/4] test: update requirement to Labgrid v25.0 Ahmad Fatoum
                   ` (4 more replies)
  0 siblings, 5 replies; 12+ messages in thread
From: Ahmad Fatoum @ 2025-07-08 19:35 UTC (permalink / raw)
  To: barebox; +Cc: Dang Huynh

The --env and --fs options are very useful for passing stuff into QEMU
without having to assemble images or type stuff into the console.

Document them and add a new --graphic option that spawns either a Bochs
ISA, PCI or a ramfb graphic device depending on the target.

Ahmad Fatoum (4):
  test: update requirement to Labgrid v25.0
  test: drop now superfluous extra_args
  test: document pytest --env and --fs options
  test: add support for pytest --graphic

 Documentation/boards/emulated.rst             | 21 +++++++++++++++++++
 conftest.py                                   | 20 +++++++++++++++++-
 test/Containerfile                            |  2 +-
 test/arm/a15@multi_v7_defconfig.yaml          |  2 +-
 test/arm/a9@multi_v7_defconfig.yaml           |  2 +-
 .../qemu-raspi0@multi_v5_v6_defconfig.yaml    |  2 +-
 .../qemu-raspi1ap@multi_v5_v6_defconfig.yaml  |  2 +-
 test/arm/qemu-raspi2b@multi_v7_defconfig.yaml |  2 +-
 test/arm/qemu-raspi3b@multi_v8_defconfig.yaml |  1 +
 .../qemu-sabrelite@multi_v7_defconfig.yaml    |  1 +
 test/arm/virt@multi_v7_defconfig.yaml         |  2 +-
 test/arm/virt@multi_v8_defconfig.yaml         |  2 +-
 test/mips/be@qemu-malta_defconfig.yaml        |  2 +-
 test/mips/qemu-malta64el_defconfig.yaml       |  2 +-
 test/mips/qemu-maltael_defconfig.yaml         |  2 +-
 test/openrisc/generic_defconfig.yaml          |  2 +-
 test/riscv/qemu-virt64@rv64i_defconfig.yaml   |  2 +-
 test/riscv/qemu@virt32_defconfig.yaml         |  2 +-
 test/riscv/sifive@rv64i_defconfig.yaml        |  2 +-
 test/strategy.py                              |  4 ++--
 test/x86/pc@efi_defconfig.yaml                |  1 +
 test/x86/q35@efi_defconfig.yaml               |  1 +
 test/x86/virtio@efi_defconfig.yaml            |  1 +
 23 files changed, 62 insertions(+), 18 deletions(-)

-- 
2.39.5




^ permalink raw reply	[flat|nested] 12+ messages in thread
* [PATCH] fixup! test: add support for pytest --graphic
@ 2025-08-06 16:32 Ahmad Fatoum
  2025-08-07  5:12 ` Sascha Hauer
  0 siblings, 1 reply; 12+ messages in thread
From: Ahmad Fatoum @ 2025-08-06 16:32 UTC (permalink / raw)
  To: barebox; +Cc: Ahmad Fatoum

test: qemu: pass -nographic in the default case.

Otherwise, we end up with an error message if the default is to use a
graphic backend.

Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
 conftest.py | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/conftest.py b/conftest.py
index 45e8835924b3..e8de5952efb4 100644
--- a/conftest.py
+++ b/conftest.py
@@ -116,9 +116,10 @@ def strategy(request, target, pytestconfig):
         else:
             pytest.exit("barebox currently supports only a single extra virtio console\n", 1)
 
-    graphics = None
-    if pytestconfig.option.qemu_graphics:
-        if qemu_bin == "qemu-system-x86_64":
+    if qemu_bin is not None:
+        if not pytestconfig.option.qemu_graphics:
+            graphics = '-nographic'
+        elif qemu_bin == "qemu-system-x86_64":
             graphics = '-device isa-vga'
         elif 'pci' in features:
             graphics = '-device VGA'
-- 
2.39.5




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

end of thread, other threads:[~2025-08-07  6:03 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-07-08 19:35 [PATCH 0/4] test: add/document pytest --graphic, --env, --fs Ahmad Fatoum
2025-07-08 19:35 ` [PATCH 1/4] test: update requirement to Labgrid v25.0 Ahmad Fatoum
2025-07-08 19:35 ` [PATCH 2/4] test: drop now superfluous extra_args Ahmad Fatoum
2025-07-08 19:35 ` [PATCH 3/4] test: document pytest --env and --fs options Ahmad Fatoum
2025-07-08 19:36 ` [PATCH 4/4] test: add support for pytest --graphic Ahmad Fatoum
2025-08-06  6:19   ` [PATCH] fixup! " Sascha Hauer
2025-08-06  6:20     ` Sascha Hauer
2025-08-06  7:40     ` Ahmad Fatoum
2025-08-07  6:02   ` [PATCH 4/4] " Sascha Hauer
2025-08-05  9:26 ` [PATCH 0/4] test: add/document pytest --graphic, --env, --fs Sascha Hauer
2025-08-06 16:32 [PATCH] fixup! test: add support for pytest --graphic Ahmad Fatoum
2025-08-07  5:12 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox