Re: [PATCH 06/15] apply tests: use "test_must_fail" instead of ad-hoc pattern

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

 



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

>  test_expect_success 'apply should fail gracefully' '
> -
> -	if git apply --index patch
> -	then
> -		echo Oops, should not have succeeded
> -		false
> -	else
> -		status=$? &&
> -		echo "Status was $status" &&
> -		if test -f .git/index.lock
> -		then
> -			echo Oops, should not have crashed
> -			false
> -		fi
> -	fi
> +	test_must_fail git apply --index patch &&
> +	test_path_is_missing .git/index.lock
>  '

Wow, that is very old fashioned.  Thanks for cleaning up the
leftover mess from the days before test_must_fail was prevalent.




[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