]> Git Repo - J-u-boot.git/blobdiff - test/ut.c
phy: test: Implement sandbox PHY .set_mode and DM test
[J-u-boot.git] / test / ut.c
index ae99831ac8ff73854ff2239d47528a5b1f6948ea..7454da3e001f5953989bd702cec0c14c996fea7d 100644 (file)
--- a/test/ut.c
+++ b/test/ut.c
@@ -59,9 +59,11 @@ static int readline_check(struct unit_test_state *uts)
                ut_fail(uts, __FILE__, __LINE__, __func__,
                        "Console record buffer too small - increase CONFIG_CONSOLE_RECORD_OUT_SIZE");
                return ret;
+       } else if (ret == -ENOENT) {
+               strcpy(uts->actual_str, "<no-more-output>");
        }
 
-       return 0;
+       return ret;
 }
 
 int ut_check_console_line(struct unit_test_state *uts, const char *fmt, ...)
@@ -79,8 +81,8 @@ int ut_check_console_line(struct unit_test_state *uts, const char *fmt, ...)
                return -EOVERFLOW;
        }
        ret = readline_check(uts);
-       if (ret < 0)
-               return ret;
+       if (ret == -ENOENT)
+               return 1;
 
        return strcmp(uts->expect_str, uts->actual_str);
 }
This page took 0.024646 seconds and 4 git commands to generate.