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

Re: t6392 broken on pu (Mac OS X)

From
Eric Sunshine <sunshine@sunshineco.com>
Date
May 9, 2016, 16:30 UTC
Message-ID
<CAPig+cQ2kSVzy0K303J3Guhk3-NzcReb5V7ohqOy2pPL_5GrSA@mail.gmail.com>
In-Reply-To
<20160509160725.GA11861@sigill.intra.peff.net>
On Mon, May 9, 2016 at 12:07 PM, Jeff King <peff@peff.net> wrote:
Show 42 quoted lines
> On Sat, May 07, 2016 at 06:15:19PM +0200, Torsten Bögershausen wrote:
>> These tests fail here under Mac OS,
>> they pass under Linux:
>> commit ff3d9b660a4b6e9d3eeb664ce1febe717adff737
>> I haven't had a chance to dig further.
>
> I assume you mean t6302. It looks like the difference is not Mac OS, but
> rather that the GPG prerequisite is not fulfilled, so we are missing a
> few of the tags.
>
> Commit 618310a introduced a helper to munge the "expect" output. Using
> that fixes some of the cases, but not test 34. That one is expecting
> blank lines for tags, so test_prepare_expect doesn't know which lines
> are related to GPG.
>
> We could fix it by tweaking the test like this:
> [...snip...]
> However, I wonder if we could improve on the strategy in 618310a, and
> simply create non-signed versions of the "signed" tags when GPG is not
> available. That would make tests looking at the whole ref namespace
> more consistent. And any tests which wanted to look specifically at the
> signed attributes should be protected with the GPG prereq anyway (it
> doesn't look like there are any currently, though).
>
> I.e., something like:
> [...snip...]
>  test_expect_success 'setup some history and refs' '
> @@ -24,9 +20,12 @@ test_expect_success 'setup some history and refs' '
>         git tag -m "Annonated doubly" doubly-annotated-tag annotated-tag &&
>         if test_have_prereq GPG
>         then
> -               git tag -s -m "A signed tag" signed-tag &&
> -               git tag -s -m "Signed doubly" doubly-signed-tag signed-tag
> +               sign=-s
> +       else
> +               sign=
>         fi &&
> +       git tag $sign -m "A signed tag" signed-tag &&
> +       git tag $sign -m "Signed doubly" doubly-signed-tag signed-tag &&
>         git checkout master &&
>         git update-ref refs/odd/spot master
>  '

The latter seems very preferable, though perhaps it could be made more concise like this?

    sign=
    test_have_prereq GPG && sign=-s
(But that's a minor issue.)
Previous: Jeff KingNext: Jeff King
Message 3 of 9 in “t6392 broken on pu (Mac OS X)”
  1. Torsten BögershausenMay 7, 2016
  2. Jeff KingMay 9, 2016
  3. Eric SunshineMay 9, 2016
  4. t6302: simplify non-gpg casesJeff King, May 9, 2016
  5. Eric SunshineMay 9, 2016
  6. t6302: simplify non-gpg casesJeff King, May 10, 2016
  7. Eric SunshineMay 10, 2016
  8. Junio C HamanoMay 10, 2016
  9. Eric SunshineMay 9, 2016

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.