Re: [PATCH] btrfs-progs: tests: Introduce expand_command() to inject aruguments more accurately

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

 



On Mon, Mar 30, 2020 at 03:02:32PM +0800, Qu Wenruo wrote:
> +_is_target_command()
> +{
> +	if [[ $1 =~ /btrfs$ ]]; then
> +		return 0
> +	fi
> +	if [[ $1 =~ /mkfs.btrfs$ ]]; then
> +		return 0
> +	fi
> +	if [[ $1 =~ /btrfs-convert$ ]]; then
> +		return 0
> +	fi
> +	return 1

I think we want all commands, so this should also include btrfstune,
btrfs-corrupt-block, btrfs-image, btrfs-select-super, btrfs-find-root.
As the list grew, a shorter form of the checks would be better, like

	[[ $1 =~ /btrfs$ ]] && return 0

I'm testing the changes with a stub instrument script, there are some
failures still.



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

  Powered by Linux