From 1cb4afc60b8e4260e20617b35d5811e934117bb5 Mon Sep 17 00:00:00 2001 From: Brian Daniels Date: Fri, 22 May 2015 10:16:05 -0500 Subject: [PATCH] Returns IO_FAIL when inital output is incorrect instead of IO_SERIAL --- workspace_tools/host_tests/wfi_auto.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/workspace_tools/host_tests/wfi_auto.py b/workspace_tools/host_tests/wfi_auto.py index b51beca13f..5f9e211548 100644 --- a/workspace_tools/host_tests/wfi_auto.py +++ b/workspace_tools/host_tests/wfi_auto.py @@ -25,9 +25,13 @@ class WFITest(): def test(self, selftest): result = True c = selftest.mbed.serial_readline() - if c is None or c.strip() != "0": + + if c is None return selftest.RESULT_IO_SERIAL + if c.strip() != "0": + return selftest.RESULT_IO_FAIL + # Wait 10 seconds to allow serial prints (indicating failure) selftest.mbed.set_serial_timeout(10)