Re: [PATCH 1/4] test-lib-functions: introduce test_line_count_cmd

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

 



Ævar Arnfjörð Bjarmason <avarab@xxxxxxxxx> writes:

> More generally speaking we have a bunch of helpers that have this
> potential issue/bug, in practice it's not a big deal.  A test that's
> being overly specific and doing a test_cmp on unbounded "find" output or
> whatever is likely buggy anyway.

Unless we are testing ".gitignore", "ls-files -o", or "git status".
Carving out $TRASH_DIRECTORY/.git/trash/ directory to store these
throwaway files would be less error prone from that point of view.

>> +		case "$1" in
>> +		--out)
>> +			outop="$2"
>> +			outval="$3"
>> +			;;
>> +		--err)
>> +			errop="$2"
>> +			errval="$3"
>> +			;;
>
> It looks like the end-state of the series leaves us with no user of the
> --err option; Maybe it's good to have it anyway for completeness, or
> just skip it? ...

I'd rather not to see --out added if we have not yet any use for the
other one.  When the time comes that we want to validate the error
stream, we may find that we want to check _both_, and we'd have to
discard dead code and replace with what we want, instead of just
adding what we want to a working code without dead code.




[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