Re: [PATCH 00/10] Hash-independent tests (part 1)
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Mar 26, 2018, 04:48 UTC
- Message-ID
- <xmqq8tafe92r.fsf@gitster-ct.c.googlers.com>
- In-Reply-To
- <CAPig+cR==SNfGdhwqPdvW75fUxXg-VSQ5Tz_OR7Sy_c0L94axQ@mail.gmail.com>
Eric Sunshine <sunshine@sunshineco.com> writes:
Show 9 quoted lines
> What's the plan for oddball cases such as 66ae9a57b8 (t3404: rebase > -i: demonstrate short SHA-1 collision, 2013-08-23) which depend > implicitly upon SHA-1 without actually hardcoding any hashes? The test > added by 66ae9a57b8, for instance, won't start failing in the face of > NewHash, but it also won't be testing anything meaningful. > > Should such tests be dropped altogether? Should they be marked with a > 'SHA1' predicate or be annotated with a comment as being > SHA-1-specific? Something else?
Ideally, the existing one be annotated with prereq SHA1, and also duplicated with a tweak to cause the same kind of (half-)collision under the NewHash and be annotated with prereq NewHash.
It's a different matter how feasible it is to attain such an ideal, though. t1512 was fun to write, but it was quite a lot of work to come up with bunch of blobs, trees and commits whose object names share the common prefix 0{10}.