refs: convert delete_ref and refs_delete_ref to struct object_id
[gitweb.git] / t / t0012-help.sh
index 920a663c3e254ec29fb2bcac2f403719ac435119..487b92a5de3238821ed3d8aadadb1f07d35e0609 100755 (executable)
@@ -41,4 +41,24 @@ test_expect_success "--exclude-guides does not work for guides" '
        test_must_be_empty test-browser.log
 '
 
+test_expect_success "--help does not work for guides" "
+       cat <<-EOF >expect &&
+               git: 'revisions' is not a git command. See 'git --help'.
+       EOF
+       test_must_fail git revisions --help 2>actual &&
+       test_i18ncmp expect actual
+"
+
+test_expect_success 'generate builtin list' '
+       git --list-builtins >builtins
+'
+
+while read builtin
+do
+       test_expect_success "$builtin can handle -h" '
+               test_expect_code 129 git $builtin -h >output 2>&1 &&
+               test_i18ngrep usage output
+       '
+done <builtins
+
 test_done