Subject: Re: [PATCH v7 1/8] checkout tests: index should be clean after dwim checkout

From: SZEDER Gábor <[email-masked]>
Date: Tue, 5 Jun 2018 17:45:01 +0200

> diff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh
> index 3e5ac81bd2..ed32828105 100755
> --- a/t/t2024-checkout-dwim.sh
> +++ b/t/t2024-checkout-dwim.sh
> @@ -23,6 +23,12 @@ test_branch_upstream () {
>  	test_cmp expect.upstream actual.upstream
>  }
>  
> +status_uno_is_clean() {
> +	>status.expect &&
> +	git status -uno --porcelain >status.actual &&
> +	test_cmp status.expect status.actual

This function could be written a tad simpler as:

  git status -uno --porcelain >status.actual &&
  test_must_be_empty status.actual