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

Re: [PATCHv3 0/5] Simple fixes to t7406

From
SZEDER Gábor <szeder.dev@gmail.com>
Date
Aug 13, 2018, 20:28 UTC
Message-ID
<CAM0VKjn6QAp-hQa3Qp07qZ2unNk20SXYoPwwFbpiLfqqx+KV+A@mail.gmail.com>
In-Reply-To
<20180807164905.3859-1-newren@gmail.com>
On Tue, Aug 7, 2018 at 6:49 PM Elijah Newren <newren@gmail.com> wrote:
Show 5 quoted lines
> Since folks like to notice other problems with t7406 while reading my
> patches, here's a challenge:
>
>   Find something *else* wrong with t7406 that neither I nor any of the
>   reviewers so far have caught that could be fixed.

Well, I'd hate to be that guy... but since those who already commented on previous rounds are not explicitly excluded from the challenge, let's see.

- There are still a few command substitutions running git commands,
  where the exit status of that command is ignored; just look for the
  '[^=]$(' pattern in the test script.
  (Is not noticing those cases considered as "flubbing"?)
- The 'compare_head' helper function defined in this test script looks
  very similar to the generally available 'test_cmp_rev' function,
  which has the benefit to provide some visible output on failure
  (though, IMO, not a particularly useful output, because the diff of
  two OIDs is not very informative, but at least it's something as
  opposed to the silence of 'test $this = $that").
  Now, since 'compare_head' always compares the same two revisions,
  namely 'master' and HEAD, replacing 'compare_head' with an
  appropriate 'test_cmp_rev' call would result in repeating 'master'
  and 'HEAD' arguments all over the test script.  I'm not sure whether
  that's good or bad.  Anyway, I think that 'compare_head' could be
  turned into a wrapper around 'test_cmp_rev'.
Show 7 quoted lines
>     - You get bonus points if that thing is in the context region for
>       one of my five patches.
>     - Extra bonus points if the thing needing fixing was on a line I
>       changed.
>     - You win outright if it's something big enough that I give up and
>       request to just have my series merged as-is and punt your
>       suggested fixes down the road to someone else.

Well, there's always the indentation of the commands run in subshells, which doesn't conform to our coding style...

Gah, now you made me that guy ;)
>   (Note: If I flubbed something in v3, pointing it out doesn't count
>    as finding "something else", but do please still point it out.)
>
> :-)
Previous: Elijah NewrenNext: Elijah Newren
Message 32 of 33 in “t7406: Make a test_must_fail call fail for the right reason”
  1. t7406: Make a test_must_fail call fail for the right reasonElijah Newren, Aug 3, 2018
  2. Junio C HamanoAug 3, 2018
  3. Eric SunshineAug 3, 2018
  4. Eric SunshineAug 3, 2018
  5. 0/2 Simple fixes to t7406Elijah Newren, Aug 6, 2018
  6. 1/3 t7406: simplify by using diff --name-only instead of diff --rawElijah Newren, Aug 6, 2018
  7. 2/3 t7406: avoid having git commands upstream of a pipeElijah Newren, Aug 6, 2018
  8. SZEDER GáborAug 6, 2018
  9. Elijah NewrenAug 6, 2018
  10. 3/3 t7406: make a test_must_fail call fail for the right reasonElijah Newren, Aug 6, 2018
  11. SZEDER GáborAug 7, 2018
  12. Elijah NewrenAug 7, 2018
  13. Martin ÅgrenAug 7, 2018
  14. Elijah NewrenAug 7, 2018
  15. 0/5 Simple fixes to t7406Elijah Newren, Aug 7, 2018
  16. 1/5 t7406: simplify by using diff --name-only instead of diff --rawElijah Newren, Aug 7, 2018
  17. Junio C HamanoAug 7, 2018
  18. Elijah NewrenAug 7, 2018
  19. Junio C HamanoAug 7, 2018
  20. 3/5 t7406: prefer test_* helper functions to test -[feds]Elijah Newren, Aug 7, 2018
  21. Junio C HamanoAug 7, 2018
  22. 5/5 t7406: fix call that was failing for the wrong reasonElijah Newren, Aug 7, 2018
  23. Junio C HamanoAug 7, 2018
  24. 4/5 t7406: avoid using test_must_fail for commands other than gitElijah Newren, Aug 7, 2018
  25. 2/5 t7406: avoid having git commands upstream of a pipeElijah Newren, Aug 7, 2018
  26. 0/5 Simple fixes to t7406Elijah Newren, Aug 8, 2018
  27. 5/5 t7406: avoid using test_must_fail for commands other than gitElijah Newren, Aug 8, 2018
  28. 2/5 t7406: simplify by using diff --name-only instead of diff --rawElijah Newren, Aug 8, 2018
  29. 4/5 t7406: prefer test_* helper functions to test -[feds]Elijah Newren, Aug 8, 2018
  30. 1/5 t7406: fix call that was failing for the wrong reasonElijah Newren, Aug 8, 2018
  31. 3/5 t7406: avoid having git commands upstream of a pipeElijah Newren, Aug 8, 2018
  32. SZEDER GáborAug 13, 2018
  33. Elijah NewrenAug 18, 2018

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.