Re: [PATCH] t: add clone test for files differing only in case
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Jan 21, 2018, 07:46 UTC
- Message-ID
- <CAPig+cTW+vO7FWYViUrO-aV8pPL=KKhGf7Wkgh_51cbrxKZPEQ@mail.gmail.com>
- In-Reply-To
- <xmqqa7x7oecq.fsf@gitster.mtv.corp.google.com>
On Sun, Jan 21, 2018 at 2:33 AM, Junio C Hamano <gitster@pobox.com> wrote:
Show 25 quoted lines
> "brian m. carlson" <sandals@crustytoothpaste.net> writes:
>> +test_expect_success 'clone on case-insensitive fs' '
>> + o=$(git hash-object -w --stdin </dev/null | hex2oct) &&
>> + t=$(printf "100644 X\0${o}100644 x\0${o}" |
>> + git hash-object -w -t tree --stdin) &&
>> + c=$(git commit-tree -m bogus $t) &&
>> + git update-ref refs/heads/bogus $c &&
>> + git clone -b bogus . bogus
>> +'
>> +
>> test_done
>
> Hmm, I seem to be seeing a failure from this thing:
>
> expecting success:
> o=$(git hash-object -w --stdin </dev/null | hex2oct) &&
> t=$(printf "100644 X\0${o}100644 x\0${o}" |
> git hash-object -w -t tree --stdin) &&
> c=$(git commit-tree -m bogus $t) &&
> git update-ref refs/heads/bogus $c &&
> git clone -b bogus . bogus
>
> fatal: repository '.' does not exist
>
> even on a case sensitive platform.Yep. In pretty much any other test script, this would work (it was developed in a stand-alone script), but t5601 (which nukes .git as its first action) isn't the most friendly place.