summaryrefslogtreecommitdiff
path: root/test/py/tests/test_extension.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_extension.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_extension.py')
-rw-r--r--test/py/tests/test_extension.py32
1 files changed, 16 insertions, 16 deletions
diff --git a/test/py/tests/test_extension.py b/test/py/tests/test_extension.py
index 2a3c5116171..61223496054 100644
--- a/test/py/tests/test_extension.py
+++ b/test/py/tests/test_extension.py
@@ -6,50 +6,50 @@
import os
import pytest
-import u_boot_utils
+import utils
overlay_addr = 0x1000
SANDBOX_DTB='arch/sandbox/dts/sandbox.dtb'
OVERLAY_DIR='arch/sandbox/dts/'
-def load_dtb(u_boot_console):
- u_boot_console.log.action('Loading devicetree to RAM...')
- u_boot_console.run_command('host load hostfs - $fdt_addr_r %s' % (os.path.join(u_boot_console.config.build_dir, SANDBOX_DTB)))
- u_boot_console.run_command('fdt addr $fdt_addr_r')
+def load_dtb(ubman):
+ ubman.log.action('Loading devicetree to RAM...')
+ ubman.run_command('host load hostfs - $fdt_addr_r %s' % (os.path.join(ubman.config.build_dir, SANDBOX_DTB)))
+ ubman.run_command('fdt addr $fdt_addr_r')
@pytest.mark.buildconfigspec('cmd_fdt')
@pytest.mark.boardspec('sandbox')
-def test_extension(u_boot_console):
+def test_extension(ubman):
"""Test the 'extension' command."""
- load_dtb(u_boot_console)
+ load_dtb(ubman)
- output = u_boot_console.run_command('extension list')
+ output = ubman.run_command('extension list')
# extension_bootdev_hunt may have already run.
# Without reboot we cannot make any assumption here.
# assert('No extension' in output)
- output = u_boot_console.run_command('extension scan')
+ output = ubman.run_command('extension scan')
assert output == 'Found 2 extension board(s).'
- output = u_boot_console.run_command('extension list')
+ output = ubman.run_command('extension list')
assert('overlay0.dtbo' in output)
assert('overlay1.dtbo' in output)
- u_boot_console.run_command_list([
+ ubman.run_command_list([
'setenv extension_overlay_addr %s' % (overlay_addr),
- 'setenv extension_overlay_cmd \'host load hostfs - ${extension_overlay_addr} %s${extension_overlay_name}\'' % (os.path.join(u_boot_console.config.build_dir, OVERLAY_DIR))])
+ 'setenv extension_overlay_cmd \'host load hostfs - ${extension_overlay_addr} %s${extension_overlay_name}\'' % (os.path.join(ubman.config.build_dir, OVERLAY_DIR))])
- output = u_boot_console.run_command('extension apply 0')
+ output = ubman.run_command('extension apply 0')
assert('bytes read' in output)
- output = u_boot_console.run_command('fdt print')
+ output = ubman.run_command('fdt print')
assert('button3' in output)
- output = u_boot_console.run_command('extension apply all')
+ output = ubman.run_command('extension apply all')
assert('bytes read' in output)
- output = u_boot_console.run_command('fdt print')
+ output = ubman.run_command('fdt print')
assert('button4' in output)