From: Junio C Hamano Date: Tue, 16 Oct 2018 05:59:59 GMT Subject: Re: [PATCH v4] branch: introduce --show-current display option Message-ID: In-Reply-To: <20181012133321.20580-1-daniels@umanovskis.se> Daniels Umanovskis writes: > +test_expect_success 'git branch `--show-current` works properly with worktrees' ' > + cat >expect <<-\EOF && > + branch-one > + branch-two > + EOF > + git checkout branch-one && > + git worktree add worktree branch-two && > + ( > + git branch --show-current && > + cd worktree && > + git branch --show-current This is not wrong per-se, but git branch --show-current && git -C worktree branch --show-current would be shorter. > + ) >actual && > + test_cmp expect actual > +'