The distro test takes a little longer to shut down and restart, so add more time to this operation.
Disable the sleep command for now, as it seems to be unreliable on QEMU with '-cpu host'. More thought will be needed for both of these problems. Signed-off-by: Simon Glass <s...@chromium.org> --- (no changes since v1) test/py/console_base.py | 8 ++++---- test/py/tests/test_sleep.py | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/test/py/console_base.py b/test/py/console_base.py index 073ab0462dc..6d0f56f841d 100644 --- a/test/py/console_base.py +++ b/test/py/console_base.py @@ -464,7 +464,7 @@ class ConsoleBase(object): finally: self.p.timeout = orig_timeout - def ensure_spawned(self, expect_reset=False): + def ensure_spawned(self, expect_reset=False, timeout=None): """Ensure a connection to a correctly running U-Boot instance. This may require spawning a new Sandbox process or resetting target @@ -485,7 +485,7 @@ class ConsoleBase(object): # Reset the console timeout value as some tests may change # its default value during the execution if not self.config.gdbserver: - self.p.timeout = TIMEOUT_MS + self.p.timeout = timeout or TIMEOUT_MS return try: self.log.start_section('Starting U-Boot') @@ -496,7 +496,7 @@ class ConsoleBase(object): # future, possibly per-test to be optimal. This works for 'help' # on board 'seaboard'. if not self.config.gdbserver: - self.p.timeout = TIMEOUT_MS + self.p.timeout = timeout or TIMEOUT_MS self.p.logfile_read = self.logstream if self.config.use_running_system: # Send an empty command to set up the 'expect' logic. This has @@ -544,7 +544,7 @@ class ConsoleBase(object): def restart_uboot(self, expect_reset=False): """Shut down and restart U-Boot.""" self.cleanup_spawn() - self.ensure_spawned(expect_reset) + self.ensure_spawned(expect_reset, 60 * 1000) def get_spawn_output(self): """Return the start-up output from U-Boot diff --git a/test/py/tests/test_sleep.py b/test/py/tests/test_sleep.py index f1bf34e05b2..2285a815813 100644 --- a/test/py/tests/test_sleep.py +++ b/test/py/tests/test_sleep.py @@ -19,6 +19,7 @@ env__sleep_margin = 0.25 """ +@pytest.mark.role('!qemu-x86_64') def test_sleep(ubman): """Test the sleep command, and validate that it sleeps for approximately the correct amount of time.""" -- 2.43.0