summaryrefslogtreecommitdiff
path: root/test/py/tests/test_spl.py
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2025-04-07 16:40:02 -0600
committerTom Rini <trini@konsulko.com>2025-04-08 11:43:23 -0600
commitff61d6bfd1c9534d3fc2397846a5899639f2e55d (patch)
treedcfe4bc52848a5637c975a3352b57885e5b8a06d /test/py/tests/test_spl.py
parent34820924edbc4ec7803eb89d9852f4b870fa760a (diff)
parentf892a7f397a66d8d09f418d1e0e06dfb48bac27d (diff)
Merge branch 'next'
Note that this undoes the changes of commit cf6d4535cc4c ("x86: emulation: Disable bloblist for now") as that was intended only for the release due to time.
Diffstat (limited to 'test/py/tests/test_spl.py')
-rw-r--r--test/py/tests/test_spl.py15
1 files changed, 7 insertions, 8 deletions
diff --git a/test/py/tests/test_spl.py b/test/py/tests/test_spl.py
index 474f430a344..48407399039 100644
--- a/test/py/tests/test_spl.py
+++ b/test/py/tests/test_spl.py
@@ -6,16 +6,16 @@ import os.path
import pytest
@pytest.mark.buildconfigspec('spl_unit_test')
-def test_ut_spl_init(u_boot_console):
+def test_ut_spl_init(ubman):
"""Initialize data for ut spl tests."""
- fn = u_boot_console.config.source_dir + '/spi.bin'
+ fn = ubman.config.source_dir + '/spi.bin'
if not os.path.exists(fn):
data = b'\x00' * (2 * 1024 * 1024)
with open(fn, 'wb') as fh:
fh.write(data)
-def test_spl(u_boot_console, ut_spl_subtest):
+def test_spl(ubman, ut_spl_subtest):
"""Execute a "ut" subtest.
The subtests are collected in function generate_ut_subtest() from linker
@@ -29,16 +29,15 @@ def test_spl(u_boot_console, ut_spl_subtest):
implemented in C function foo_test_bar().
Args:
- u_boot_console (ConsoleBase): U-Boot console
+ ubman (ConsoleBase): U-Boot console
ut_subtest (str): SPL test to be executed (e.g. 'dm platdata_phandle')
"""
try:
- cons = u_boot_console
- cons.restart_uboot_with_flags(['-u', '-k', ut_spl_subtest.split()[1]])
- output = cons.get_spawn_output().replace('\r', '')
+ ubman.restart_uboot_with_flags(['-u', '-k', ut_spl_subtest.split()[1]])
+ output = ubman.get_spawn_output().replace('\r', '')
assert 'failures: 0' in output
finally:
# Restart afterward in case a non-SPL test is run next. This should not
# happen since SPL tests are run in their own invocation of test.py, but
# the cost of doing this is not too great at present.
- u_boot_console.restart_uboot()
+ ubman.restart_uboot()