Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH] test the commit.gpgsign config option

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:59:28
Subsystem: the rest · Maintainer: Linus Torvalds

Possibly related (same subject, not in this thread)

Junio C Hamano [off-list ref] writes:
If any of the above fail, the next test will run with an unknown
random value in commit.gpgsign depending on where the sequence
failed.  Use one test_when_finished with test_unconfig at the very
beginning, perhaps.
In other words, I'll squash this in.
diff --git a/t/t7510-signed-commit.sh b/t/t7510-signed-commit.sh
index 537bfba..5ddac1a 100755
--- a/t/t7510-signed-commit.sh
+++ b/t/t7510-signed-commit.sh
@@ -5,6 +5,8 @@ test_description='signed commit tests'
 . "$TEST_DIRECTORY/lib-gpg.sh"
 
 test_expect_success GPG 'create signed commits' '
+	test_when_finished "test_unconfig commit.gpgsign" &&
+
 	echo 1 >file && git add file &&
 	test_tick && git commit -S -m initial &&
 	git tag initial &&
@@ -40,9 +42,7 @@ test_expect_success GPG 'create signed commits' '
 	git tag seventh-unsigned &&
 
 	test_tick && git rebase -f HEAD^^ && git tag sixth-signed HEAD^ &&
-	git tag seventh-signed &&
-
-	git config --unset commit.gpgsign
+	git tag seventh-signed
 '
 
 test_expect_success GPG 'show signatures' '
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help