]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
test/py/tests/test_sleep.py: Add check for CONFIG_CMD_MISC
authorTom Rini <trini@konsulko.com>
Fri, 14 Oct 2016 23:12:31 +0000 (19:12 -0400)
committerTom Rini <trini@konsulko.com>
Fri, 14 Oct 2016 23:12:31 +0000 (19:12 -0400)
We can only run this command if the sleep command is enabled and that
depends on CONFIG_CMD_MISC

Signed-off-by: Tom Rini <trini@konsulko.com>
test/py/tests/test_sleep.py

index 5c1a2623fefa77c68f2aa6758001718aae64768f..b59a4cfc0fc295cae3cf28e81bfb3f54825aa701 100644 (file)
@@ -9,6 +9,8 @@ def test_sleep(u_boot_console):
     """Test the sleep command, and validate that it sleeps for approximately
     the correct amount of time."""
 
+    if u_boot_console.config.buildconfig.get('config_cmd_misc', 'n') != 'y':
+        pytest.skip('sleep command not supported')
     # 3s isn't too long, but is enough to cross a few second boundaries.
     sleep_time = 3
     tstart = time.time()