Re: [PATCH v2 3/3] t: add tests for safe.directory when running with sudo
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 28, 2022, 18:12 UTC
- Message-ID
- <xmqq7d79gjre.fsf@gitster.g>
- In-Reply-To
- <5493b2f1-e59d-d91d-ac21-47c93d2996f2@gmail.com>
Phillip Wood <phillip.wood123@gmail.com> writes:
Show 16 quoted lines
> On 28/04/2022 17:55, Junio C Hamano wrote: >> Carlo Marcelo Arenas Belón <carenas@gmail.com> writes: >> >>> +test_description='verify safe.directory checks while running as root' >>> + >>> +. ./test-lib.sh >>> + >>> +if [ "$IKNOWWHATIAMDOING" != "YES" ]; then >> Style. >> if test "$IKNOWWHATIAMDOING" != "YES" >> then > > Also naming - we normally prefix test environment variables with > GIT_TEST_. IKNOWWHATIAMDOING does not tell us what we are allowing by > setting the variable. Something like GIT_TEST_ALLOW_SUDO would tell us > what we're letting ourselves in for by setting it.
If this weren't "let's reuse the same mechanism as already used in 1509", I would have had the same reaction. Renaming would be better done outside the topic, I would think.
Thanks.