Re: [PATCH 8/9] Use git diff instead of diff in t7201

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 5 Feb 2008, Junio C Hamano wrote:

> Daniel Barkalow <barkalow@xxxxxxxxxxxx> writes:
> 
> > On Tue, 5 Feb 2008, Junio C Hamano wrote:
> >
> >> Daniel Barkalow <barkalow@xxxxxxxxxxxx> writes:
> >> 
> >> > Well, it's something I tripped over when builtin-checkout wasn't passing 
> >> > the tests and I couldn't figure out what it was doing wrong from the 
> >> > output. Like [3/9], it's relevant to evaluating whether the series works, 
> >> > even if it's not important for whether it actually does work.
> >> 
> >> Yeah, using "diff -u" instead of just "diff" is an improvement
> >> for debuggability which matters a lot in the test scripts.
> >
> > I think I asked before and didn't hear back (or maybe I got distracted 
> > and didn't ask); do you want this to use "diff -u" everywhere or "git 
> > diff" everywhere? This test is currently part "diff" and part "git diff", 
> > and I went for git diff" everywhere, but you seemed to prefer "diff -u".
> 
> Typically the test sequence is "do this with git, do that with
> git, produce the output with git, now what happened?  did we
> produce a correct result?"  And we often compare 'expect' and
> 'actual' to see if there are discrepancies.
> 
> My preference is NEVER using "git diff" when comparing expected
> result and the actual output from git.  When "git diff" has
> breakage, it would break unrelated tests and make debugging
> needlessly harder.

Certainly, although we seem to do a lousy job of ordering tests currently 
such that the tests that fail are the ones for the thing that's broken; it 
took a lot of work to get builtin-checkout to the point to reaching 
t7201-co.sh, and by that point it just about all worked. In any case, I'll 
go for "diff -u" all around in that test, since I'm changing it.

	-Daniel
*This .sig left intentionally blank*
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux