From 8dd0b046c2a4c9560113756ccf4cb396e0068217 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Sun, 13 Jun 2021 19:02:21 -0300 Subject: tests/cli-opts.sh: Test help flags on different position too --- tests/cli-opts.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'tests') diff --git a/tests/cli-opts.sh b/tests/cli-opts.sh index 630fd29..0ecc2ef 100755 --- a/tests/cli-opts.sh +++ b/tests/cli-opts.sh @@ -106,6 +106,22 @@ test_help_flags() { assert_empty_stderr assert_usage "$OUT" + OUT="$(mktemp)" + ERR="$(mktemp)" + ./remembering -p profile -c command --help 1>"$OUT" 2>"$ERR" + STATUS=$? + assert_status 0 + assert_empty_stderr + assert_usage "$OUT" + + OUT="$(mktemp)" + ERR="$(mktemp)" + ./remembering --help -p profile -c command 1>"$OUT" 2>"$ERR" + STATUS=$? + assert_status 0 + assert_empty_stderr + assert_usage "$OUT" + test_ok } -- cgit v1.2.3