From 2a33b9faf0be71e375d8962546a34611f2d6c1f7 Mon Sep 17 00:00:00 2001 From: Zach Brown Date: Mon, 23 Aug 2021 09:57:01 -0700 Subject: [PATCH] Add some error testing to srch-basic-functionality When the xattr inode searchs fail the test will eventually fail when the output differs, but that could take a while. Have it fail much sooner so that we can have tighter debugging interations and trace ring buffer contents that are likely to be a lot closer to the first failure. Signed-off-by: Zach Brown --- tests/tests/srch-basic-functionality.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/tests/srch-basic-functionality.sh b/tests/tests/srch-basic-functionality.sh index b310ecd4..55c709f5 100644 --- a/tests/tests/srch-basic-functionality.sh +++ b/tests/tests/srch-basic-functionality.sh @@ -17,8 +17,10 @@ diff_srch_find() local n="$1" sync - scoutfs search-xattrs "$n" -p "$T_M0" > "$T_TMP.srch" - find_xattrs -d "$T_D0" -m "$T_M0" -n "$n" > "$T_TMP.find" + scoutfs search-xattrs "$n" -p "$T_M0" > "$T_TMP.srch" || \ + t_fail "search-xattrs failed" + find_xattrs -d "$T_D0" -m "$T_M0" -n "$n" > "$T_TMP.find" || \ + t_fail "find_xattrs failed" diff -u "$T_TMP.srch" "$T_TMP.find" }