[LTP] [PATCH] commands/df01.sh: print more logs when test fails

Jan Stancek jstancek@redhat.com
Thu Jul 7 14:58:30 CEST 2022


Signed-off-by: Jan Stancek <jstancek@redhat.com>
---
 testcases/commands/df/df01.sh | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/testcases/commands/df/df01.sh b/testcases/commands/df/df01.sh
index f74032c962e5..6b20f21d0d74 100755
--- a/testcases/commands/df/df01.sh
+++ b/testcases/commands/df/df01.sh
@@ -103,6 +103,11 @@ df_check()
 
 	grep ${TST_DEVICE} output | grep -q "${total}.*${used}"
 	if [ $? -ne 0 ]; then
+		echo "total: ${total}, used: ${used}"
+		echo "df saved output:"
+		cat output
+		echo "df output:"
+		$@
 		return 1
 	fi
 }
-- 
2.27.0



More information about the ltp mailing list