summaryrefslogtreecommitdiff
path: root/test/py/u_boot_console_base.py
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2016-07-04 11:58:39 -0600
committerSimon Glass <sjg@chromium.org>2016-07-14 20:40:24 -0600
commitebec58fbcb6da7404b535b9d860546d9baef55c2 (patch)
tree2c178319877eeb1e1b7d0aed67baeecf49bafec0 /test/py/u_boot_console_base.py
parentc7f636f59d7d506b89d7fc52aa6509329e9ded1b (diff)
downloadu-boot-imx-ebec58fbcb6da7404b535b9d860546d9baef55c2.zip
u-boot-imx-ebec58fbcb6da7404b535b9d860546d9baef55c2.tar.gz
u-boot-imx-ebec58fbcb6da7404b535b9d860546d9baef55c2.tar.bz2
test/py: Provide a way to get early console output
Some tests want to check the console output from SPL or U-Boot proper. Provide a means to do this. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test/py/u_boot_console_base.py')
-rw-r--r--test/py/u_boot_console_base.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/py/u_boot_console_base.py b/test/py/u_boot_console_base.py
index 2dcb289..3d2ac44 100644
--- a/test/py/u_boot_console_base.py
+++ b/test/py/u_boot_console_base.py
@@ -377,6 +377,16 @@ class ConsoleBase(object):
pass
self.p = None
+ def get_spawn_output(self):
+ """Return the start-up output from U-Boot
+
+ Returns:
+ The output produced by ensure_spawed(), as a string.
+ """
+ if self.p:
+ return self.p.get_expect_output()
+ return None
+
def validate_version_string_in_text(self, text):
"""Assert that a command's output includes the U-Boot signon message.