Browse Source

tests: Add usage() to run-all.sh

The -h or --help command line arguments can now be used to request usage
information for run-all.sh.

Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Ilan Peer 10 years ago
parent
commit
6e04f41168
1 changed files with 11 additions and 0 deletions
  1. 11 0
      tests/hwsim/run-all.sh

+ 11 - 0
tests/hwsim/run-all.sh

@@ -24,6 +24,14 @@ else
     fi
 fi
 
+usage()
+{
+	echo "$0 [-v | --valgrind | valgrind] [-t | --trace | trace]"
+	echo "\t[-n <num> | --channels <num>] [-B | --build]"
+	echo "\t[-c | --codecov ] [run-tests.py parameters]"
+	exit 1
+}
+
 unset VALGRIND
 unset TRACE
 unset TRACE_ARGS
@@ -60,6 +68,9 @@ while [ "$1" != "" ]; do
 			CODECOV=lcov
 			BUILD_ARGS=-c
 			;;
+		-h | --help)
+			usage
+			;;
 		*)
 			RUN_TEST_ARGS="$RUN_TEST_ARGS$1 "
 			shift