Re: [PATCH] t6300: fix setup with GPGSSH but without GPG
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 17, 2023, 16:22 UTC
- Message-ID
- <xmqqwmyyik2o.fsf@gitster.g>
- In-Reply-To
- <cbc22750-af93-9274-2ed4-6dfd356568e8@web.de>
René Scharfe <l.s.r@web.de> writes:
Show 11 quoted lines
> In a test introduced by 26c9c03f0a (ref-filter: add new "signature" > atom, 2023-06-04) the file named "file" is added by a setup step that > requires GPG and modified by a second setup step that requires GPGSSH. > Systems lacking the first prerequisite skip the initial setup step and > then "git commit -a" in the second one doesn't find the modified file. > Add it explicitly. > > Signed-off-by: René Scharfe <l.s.r@web.de> > --- > t/t6300-for-each-ref.sh | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-)
Thanks for good eyes.
I guess a box without GPG is not so uncommon, and even such a box can reasonably be expected to have SSH on it, so I would believe if this was discovered on a real development box, but is that how you found this? Or have you invented a nice test helper that lets you pick random set of prerequisites and try permutations of having and not having them, or something nice like that?
Will queue.
Show 16 quoted lines
> diff --git a/t/t6300-for-each-ref.sh b/t/t6300-for-each-ref.sh
> index 6e6ec852b5..1180c3254c 100755
> --- a/t/t6300-for-each-ref.sh
> +++ b/t/t6300-for-each-ref.sh
> @@ -1584,7 +1584,8 @@ test_expect_success GPGSSH 'setup for signature atom using ssh' '
> test_config user.signingkey "${GPGSSH_KEY_PRIMARY}" &&
> echo "8" >file &&
> test_tick &&
> - git commit -a -S -m "file: 8" &&
> + git add file &&
> + git commit -S -m "file: 8" &&
> git tag eighth-signed-ssh
> '
>
> --
> 2.41.0