Re: [PATCH 2/8] Add a place for (not) sharing stuff between worktrees
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Sep 23, 2018, 07:51 UTC
- Message-ID
- <CAPig+cS-S8cnDnZfXLyz=W3fVM=Bp9ntNVab6uZqeHA9_CSUCw@mail.gmail.com>
- In-Reply-To
- <20180922180500.4689-3-pclouds@gmail.com>
On Sat, Sep 22, 2018 at 2:05 PM Nguyễn Thái Ngọc Duy <pclouds@gmail.com> wrote:
Show 22 quoted lines
> When multiple worktrees are used, we need rules to determine if > something belongs to one worktree or all of them. Instead of keeping > adding rules when new stuff comes, have a generic rule: > [...] > Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> > --- > diff --git a/t/t1415-worktree-refs.sh b/t/t1415-worktree-refs.sh > @@ -0,0 +1,36 @@ > +test_expect_success 'setup' ' > + test_commit initial && > + test_commit wt1 && > + test_commit wt2 && > + git worktree add wt1 wt1 && > + git worktree add wt2 wt2 && > + git checkout initial > +' > + > +test_expect_success 'add refs/local' ' > + git update-ref refs/local/foo HEAD && > + git -C wt1 update-ref refs/local/foo HEAD && > + git -C wt2 update-ref refs/local/foo HEAD > +'
Not at all worth a re-roll, but the "add refs/local" test seems like just more setup, thus could be rolled into the "setup" test (unless it will be growing in some non-setup way in later patches).