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

t4204-patch-id failures

From
Armin Kunaschik <megabreit@googlemail.com>
Date
May 23, 2016, 16:30 UTC
Message-ID
<CALR6jEgf_FiGWs=45+n8uzKEiXU7yKDsP+CjOUAWu1CnUXZbPw@mail.gmail.com>
Hello,
I see 3 test failures in t4202:
expecting success:
        test_patch_id_file_order irrelevant --stable --stable

Already on 'same' cmp: cannot open patch-id_ordered-ordered-order---stable-irrelevant not ok 7 - file order is irrelevant with --stable # # test_patch_id_file_order irrelevant --stable --stable #

expecting success:
        test_patch_id_file_order relevant --unstable --unstable

Already on 'same' cmp: cannot open patch-id_ordered-ordered-order---unstable-relevant [..]

expecting success:
        test_config patchid.stable true &&
        test_patch_id irrelevant patchid.stable=true

Already on 'same' cmp: cannot open patch-id_ordered-ordered-order-patchid.stable=true-irrelevant not ok 10 - patchid.stable = true is stable # # test_config patchid.stable true && # test_patch_id irrelevant patchid.stable=true # [..]

expecting success:
        test_config patchid.stable false &&
        test_patch_id irrelevant patchid.stable=false--stable --stable

Already on 'same' cmp: cannot open patch-id_ordered-ordered-order-patchid.stable=false--stable-irrelevant not ok 13 - --stable overrides patchid.stable = false # # test_config patchid.stable false && # test_patch_id irrelevant patchid.stable=false--stable --stable #

Please notice the double "ordered"! From my point of view there is a problem in the function calc_patch_id() which changes the variable $name and causes the test to fail.

Essentially it's working like this: <snip> #!/bin/bash

func1() {
        name=${1}
        echo "func1 name=$name"
}
func2() {
        name=${1}
        echo "func2 name=$name"
        func1 "ordered-$name"
        echo "func2 again name=$name"
}

func2 foo <snip> which prints in bash, ksh88 and ksh93 on Linux and AIX the same func2 name=foo func1 name=ordered-foo func2 again name=ordered-foo

I wonder if those 3 tests ever worked... and why? :-)

A suggested patch would be to rename $name inside calc_patch_id into something else except $name... e.g. $pname.

Armin
Next: Junio C Hamano
Message 1 of 4 in “t4204-patch-id failures”
  1. Armin KunaschikMay 23, 2016
  2. Junio C HamanoMay 23, 2016
  3. Junio C HamanoMay 23, 2016
  4. Armin KunaschikMay 23, 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.