git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/5] t1400: set core.logAllRefUpdates in "logged by touch" tests

From
Kyle Meyer <kyle@kyleam.com>
Date
Mar 22, 2017, 01:57 UTC
Message-ID
<87k27ikr8x.fsf@kyleam.com>
In-Reply-To
<20170321014920.qas2xbbx66zqo5lp@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
> On Mon, Mar 20, 2017 at 08:56:13PM -0400, Kyle Meyer wrote:
[...]
Show 25 quoted lines
>> I'm confused about the setup for the "logged by touch" tests.
>> d0ab05849 (tests: remove some direct access to .git/logs, 2015-07-27)
>> changed the setup to delete the log file itself rather than its
>> contents.  The reflog was then recreated by using "--create-reflog" in
>> the "create $m (logged by touch)" test.  What I don't understand is
>> how this change fits with d0ab05849, which seems to be concerned with
>> loosening the assumption that the logs are stored in .git/logs.
>
> I suspect the answer is that the conversion was incomplete. That commit
> was done for alternate ref backends, which is an ongoing saga.
>
> I think it's OK to leave it as-is for now. It's not clear what "logged
> by touch" will look like for backends that don't use the filesystem.
> Probably it will need to call "update-ref --create-reflog" to kickstart
> it, and then further updates will automatically write to it.
>
> At that point the "rm -f" would need to become "tell the backend to
> delete this reflog". There's no command for that now, but we can add one
> later. Until then, I suspect the "rm -f" would be a noop. That means
> that the first --create-reflog test is failing to test what it claims,
> but the result passes anyway.
>
> And that probably answers the question about why the conversion is
> half-done. It was enough to get the tests to stop complaining when built
> with an alternate ref backend. :)
OK, thanks for the background.
-- 
Kyle
Previous: Jeff KingNext: Kyle Meyer
Message 6 of 16 in “t1400: modernize style”
  1. 0/5 t1400: modernize styleKyle Meyer, Mar 21, 2017
  2. 1/5 t1400: rename test descriptions to be uniqueKyle Meyer, Mar 21, 2017
  3. Jeff KingMar 21, 2017
  4. 2/5 t1400: set core.logAllRefUpdates in "logged by touch" testsKyle Meyer, Mar 21, 2017
  5. Jeff KingMar 21, 2017
  6. Kyle MeyerMar 22, 2017
  7. 3/5 t1400: use test_path_is_* helpersKyle Meyer, Mar 21, 2017
  8. Jeff KingMar 21, 2017
  9. 4/5 t1400: remove a set of unused output filesKyle Meyer, Mar 21, 2017
  10. Jeff KingMar 21, 2017
  11. 5/5 t1400: use test_when_finished for cleanupKyle Meyer, Mar 21, 2017
  12. Jeff KingMar 21, 2017
  13. Jeff KingMar 21, 2017
  14. Junio C HamanoMar 21, 2017
  15. Kyle MeyerMar 22, 2017
  16. Kyle MeyerMar 22, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.