]> git.ipfire.org Git - thirdparty/git.git/commitdiff
Merge branch 'tz/test-prepare-gnupghome'
authorJunio C Hamano <gitster@pobox.com>
Tue, 4 Nov 2025 15:48:07 +0000 (07:48 -0800)
committerJunio C Hamano <gitster@pobox.com>
Tue, 4 Nov 2025 15:48:07 +0000 (07:48 -0800)
Tests did not set up GNUPGHOME correctly, which is fixed but some
flaky tests are exposed in t1016, which needs to be addressed
before this topic can move forward.

* tz/test-prepare-gnupghome:
  t/lib-gpg: call prepare_gnupghome() in GPG2 prereq
  t/lib-gpg: add prepare_gnupghome() to create GNUPGHOME dir

1  2 
t/lib-gpg.sh

diff --cc t/lib-gpg.sh
index b99ae39a06b68395e3288c15d494f6637c724cd4,21666b2ab066c2b007e3a9c1437a5d18fdaac225..97268ae07c46f8879579c7638b413bae4326345e
@@@ -71,15 -66,8 +71,16 @@@ test_lazy_prereq GPG2 
                exit 1
                ;;
        *)
+               prepare_gnupghome &&
                (gpgconf --kill all || : ) &&
 +
 +              # NEEDSWORK: prepare_gnupghome() should definitely be
 +              # called here, but it looks like it exposes a
 +              # pre-existing, hidden bug by allowing some tests in
 +              # t1016-compatObjectFormat.sh to run instead of being
 +              # skipped. See:
 +              # https://lore.kernel.org/git/ZoV8b2RvYxLOotSJ@teonanacatl.net/
 +
                gpg --homedir "${GNUPGHOME}" --import \
                        "$TEST_DIRECTORY"/lib-gpg/keyring.gpg &&
                gpg --homedir "${GNUPGHOME}" --import-ownertrust \