Re: [PATCH 1/3] fsck: verify commit graph when implicitly enabled
- From
Taylor Blau <me@ttaylorr.com>
- Date
- Sep 13, 2021, 19:36 UTC
- Message-ID
- <YT+oL15j6Xq05RmS@nand.local>
- In-Reply-To
- <CAPig+cRbSUaahdRr9pj9==_7g0Om-Zax93zBRBiJg0-X7zXnOA@mail.gmail.com>
On Mon, Sep 13, 2021 at 03:33:40PM -0400, Eric Sunshine wrote:
Show 16 quoted lines
> On Mon, Sep 13, 2021 at 3:29 PM Taylor Blau <me@ttaylorr.com> wrote: > > On Mon, Sep 13, 2021 at 11:12:19AM -0700, Glen Choo wrote: > > > +test_expect_success 'git fsck (ignores commit-graph when config set to false)' ' > > > + cd "$TRASH_DIRECTORY/full" && > > > + git fsck && > > > + corrupt_graph_and_verify $GRAPH_BYTE_FOOTER "\00" \ > > > + "incorrect checksum" && > > > + cp commit-graph-pre-write-test $objdir/info/commit-graph && > > > + git -c core.commitGraph=false fsck > > > > Nit; I recommend replacing the `-c` style configuration with > > `test_config`, which modifies `$GIT_DIR/config` but only for the > > duration of the sub-shell. > > Small correction: There is no subshell here, so it would be more > accurate to say "... for the duration of the test".
Yes, sorry about that: I did not mean to say "subshell" here (Glen: hopefully you didn't read too far into that, since test_config() does not work in subshells).
Thanks for catching that, Eric.
Thanks, Taylor