[LTP] [RFC PATCH 5/9] testcases: logrotate: Check if "file" command exists

Mylène Josserand mylene.josserand@bootlin.com
Mon Apr 23 11:46:35 CEST 2018


Add "file" binary in the list of commands to check if
they exist or not.

Signed-off-by: Mylène Josserand <mylene.josserand@bootlin.com>
---
 testcases/commands/logrotate/logrotate_tests.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/testcases/commands/logrotate/logrotate_tests.sh b/testcases/commands/logrotate/logrotate_tests.sh
index f5a22ddde..021972294 100755
--- a/testcases/commands/logrotate/logrotate_tests.sh
+++ b/testcases/commands/logrotate/logrotate_tests.sh
@@ -97,10 +97,11 @@ init()
 		 return $RC
 	fi
 
-	# check if commands tst_*, logrotate, awk exists.
+	# check if commands tst_*, logrotate, awk and file exists.
 	chk_ifexists INIT tst_resm  || return $RC
 	chk_ifexists INIT logrotate || return $RC
 	chk_ifexists INIT awk       || return $RC
+	chk_ifexists INIT file      || return $RC
 
 	return $RC
 }
-- 
2.11.0



More information about the ltp mailing list