Re: [PATCH v2] generic/235: Fix false failures for some quota formats

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



On Thu, Jul 21, 2016 at 10:55:06AM +0200, Jan Kara wrote:
> Different quota format may print additional information in repquota(8)
> output after standard quota information is printed. If format does
> support this additional printouts, repquota(8) will separate possible
> output by two empty lines even if format handler doesn't actually
> printout anything (which is currently always the case for queries test
> generic/235 does). If format doesn't support additional printouts, these
> two empty lines are not present in the output. This inconsistency causes
> false failures for some quota formats.
> 
> Fix the problem by filtering out empty lines out of repquota(8) output.
> 
> Signed-off-by: Jan Kara <jack@xxxxxxx>
> ---
>  tests/generic/235     | 9 +++++++--
>  tests/generic/235.out | 8 --------
>  2 files changed, 7 insertions(+), 10 deletions(-)
> 
> diff --git a/tests/generic/235 b/tests/generic/235
> index 59456b67c092..d42054efee91 100755
> --- a/tests/generic/235
> +++ b/tests/generic/235
> @@ -46,6 +46,11 @@ _require_scratch
>  _require_quota
>  _require_user
>  
> +_repquota()
> +{
> +	repquota -u -g $SCRATCH_MNT  | grep -v -E '^root|^$' | _filter_scratch
> +}

Usually we name local functions without the leading "_", which is for
common helpers from common/rc etc. Do you mind if I rename it to
"do_repquota"?

Thanks,
Eryu
--
To unsubscribe from this list: send the line "unsubscribe fstests" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux