From: Usman Akinyemi <usmanakinyemi202@gmail•com>
To: git@vger•kernel.org
Cc: ps@pks•im, chriscool@tuxfamily•org, christian.couder@gmail•com,
gitster@pobox•com, me@ttaylorr•com, usmanakinyemi202@gmail•com
Subject: [PATCH 6/7] t/t1517: move verify-commit -h test to t1517
Date: Mon, 7 Jul 2025 02:37:24 +0530 [thread overview]
Message-ID: <20250706210725.79903-7-usmanakinyemi202@gmail.com> (raw)
In-Reply-To: <20250706210725.79903-1-usmanakinyemi202@gmail.com>
The test 'verify-commit does not crash with -h' checks that
the command exits cleanly with usage information, both inside and
outside of a repository.
Move this test from "t/t7510-signed-commit.sh" to
"t1517-outside-repo.sh" since it better fits with tests that check
command behavior outside a repository.
Suggested-by: Patrick Steinhardt <ps@pks•im>
Signed-off-by: Usman Akinyemi <usmanakinyemi202@gmail•com>
---
t/t1517-outside-repo.sh | 7 +++++++
t/t7510-signed-commit.sh | 7 -------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/t/t1517-outside-repo.sh b/t/t1517-outside-repo.sh
index a140b5cc38..42381ef7eb 100755
--- a/t/t1517-outside-repo.sh
+++ b/t/t1517-outside-repo.sh
@@ -149,4 +149,11 @@ test_expect_success 'send-pack does not crash with -h' '
test_grep "[Uu]sage: git send-pack " usage
'
+test_expect_success 'verify-commit does not crash with -h' '
+ test_expect_code 129 git verify-commit -h >usage &&
+ test_grep "[Uu]sage: git verify-commit " usage &&
+ test_expect_code 129 nongit git verify-commit -h >usage &&
+ test_grep "[Uu]sage: git verify-commit " usage
+'
+
test_done
diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh
index 39677e859a..0d2dd29fe6 100755
--- a/t/t7510-signed-commit.sh
+++ b/t/t7510-signed-commit.sh
@@ -8,13 +8,6 @@ export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
GNUPGHOME_NOT_USED=$GNUPGHOME
. "$TEST_DIRECTORY/lib-gpg.sh"
-test_expect_success GPG 'verify-commit does not crash with -h' '
- test_expect_code 129 git verify-commit -h >usage &&
- test_grep "[Uu]sage: git verify-commit " usage &&
- test_expect_code 129 nongit git verify-commit -h >usage &&
- test_grep "[Uu]sage: git verify-commit " usage
-'
-
test_expect_success GPG 'create signed commits' '
test_oid_cache <<-\EOF &&
header sha1:gpgsig
--
2.50.0
next prev parent reply other threads:[~2025-07-06 21:09 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-06 21:07 [PATCH 0/7] move builtin help test to t1517 Usman Akinyemi
2025-07-06 21:07 ` [PATCH 1/7] t/t1517: move checkout-index -h " Usman Akinyemi
2025-07-06 21:07 ` [PATCH 2/7] t/t1517: move for-each-ref " Usman Akinyemi
2025-07-06 21:07 ` [PATCH 3/7] t/t1517: move ls-files " Usman Akinyemi
2025-07-06 21:07 ` [PATCH 4/7] t/t1517: move pack-refs " Usman Akinyemi
2025-07-06 21:07 ` [PATCH 5/7] t/t1517: move send-pack " Usman Akinyemi
2025-07-06 21:07 ` Usman Akinyemi [this message]
2025-07-06 21:07 ` [PATCH 7/7] t/t1517: move verify-tag " Usman Akinyemi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250706210725.79903-7-usmanakinyemi202@gmail.com \
--to=usmanakinyemi202@gmail$(echo .)com \
--cc=chriscool@tuxfamily$(echo .)org \
--cc=christian.couder@gmail$(echo .)com \
--cc=git@vger$(echo .)kernel.org \
--cc=gitster@pobox$(echo .)com \
--cc=me@ttaylorr$(echo .)com \
--cc=ps@pks$(echo .)im \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox