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

t5505-remote.29 not working correctly

From
BCBrandon Casey <brandon.casey.ctr@nrlssc.navy.mil>
Date
Mar 16, 2010, 01:12 UTC
Message-ID
<OGVB8d37MB-s4H3VOECmd2htUvpq3B4NginojN-XskLyvHmnbfGA4Q@cipher.nrlssc.navy.mil>
Junio,
I ran across this flaw while investigating something else.

The test titled 'remote prune to cause a dangling symref' is not linked together with &&'s. When the &&'s are added, it does not complete successfully.

Here's the copy&pasted diff which adds '&&' in two places:
diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh
index a82c5ff..a3406dd 100755
--- a/t/t5505-remote.sh
+++ b/t/t5505-remote.sh
@@ -510,12 +510,12 @@ test_expect_success 'remote prune to cause a dangling symr
        ) 2>err &&
        grep "has become dangling" err &&
 
-       : And the dangling symref will not cause other annoying errors
+       : And the dangling symref will not cause other annoying errors &&
        (
                cd seven &&
                git branch -a
        ) 2>err &&
-       ! grep "points nowhere" err
+       ! grep "points nowhere" err &&
        (
                cd seven &&
                test_must_fail git branch nomore origin


The first grep causes the failure:

   ...
   (
   	cd seven &&
   	git remote prune origin
   ) 2>err &&
   grep "has become dangling" err &&
   ...

'git remote prune origin' is not printing "has become dangling".

-brandon
Next: Junio C Hamano
Message 1 of 4 in “t5505-remote.29 not working correctly”
  1. Brandon CaseyMar 16, 2010
  2. Junio C HamanoMar 16, 2010
  3. Junio C HamanoMar 16, 2010
  4. refs: ref entry with NULL sha1 is can be a dangling symrefJunio C Hamano, Mar 16, 2010

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.