On Fri, Jun 14, 2019 at 12:22 AM Junio C Hamano <gits...@pobox.com> wrote:
>
> Jeff King <p...@peff.net> writes:
>
> >> > I know there are testing philosophies that go to this level of
> >> > white-box testing, but I don't think we usually do in Git. A unit
> >> > test of oidmap's externally visible behavior seems like the right
> >> > level to me.
> >>
> >> That's a good point...  but then why does 't0011-hashmap.sh' do it in
> >> the first place?  As far as I understood this t0016 mainly follows
> >> suit of t0011.
> >
> > I'd make the same argument against t0011. :)
>
> Yeah, I tend to agree.  It is not a good excuse that somebody else
> alerady has made a mistake.

Ok, I will remove the "hash" test in t0016 and the corresponding code
in test-oidmap.c.

> > I think there it at least made a little more sense because we truly are
> > hashing ourselves, rather than just copying out some sha1 bytes. But I
> > think I'd still argue that if I updated strhash() to use a different
> > hash, I should not have to be updating t0011 to change out the hashes.
>
> True, too.

I will also send an additional patch to remove similar code in t00161
and test-hashmap.c.

Reply via email to