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

Re: [PATCH v2 11/14] t/t5505-remote: test multiple push/pull in remotes-file

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 23, 2013, 08:07 UTC
Message-ID
<7vobaxfdx9.fsf@alter.siamese.dyndns.org>
In-Reply-To
<1371887901-5659-12-git-send-email-artagnon@gmail.com>
Ramkumar Ramachandra <artagnon@gmail.com> writes:
Show 21 quoted lines
> Extend the test "migrate a remote from named file in $GIT_DIR/remotes"
> to test that multiple "Push:" and "Pull:" lines in the remotes-file
> works as expected.
>
> Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
> ---
>  t/t5505-remote.sh | 16 ++++++++++++++--
>  1 file changed, 14 insertions(+), 2 deletions(-)
>
> diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh
> index 229a89c..6a622fc 100755
> --- a/t/t5505-remote.sh
> +++ b/t/t5505-remote.sh
> @@ -735,7 +735,9 @@ test_expect_success 'rename a remote with name prefix of other remote' '
>  cat >remotes_origin <<-EOF
>  URL: quux
>  Push: refs/heads/master:refs/heads/upstream
> +Push: refs/heads/master:refs/heads/upstream2
>  Pull: refs/heads/master:refs/heads/origin
> +Pull: refs/heads/master:refs/heads/origin2
>  EOF

I do not think we ever designed this to get 'master' pushed to update two separate destination branches or their 'master' to update our two separate tracking branches.

If you want to make things more realistic like you did in 08/14, I do not see a point to change the tests that is already done for a useful and realistic case by making it deliberately less realistic.

The same comment applies to the bogus quux URL from the patch 04/14.

I'll reject 04/14 and tweak this patch to use 'next' for the new ref mappings, not duplicated 'master'.

Patches 07/14, 12/14, 13/14, and 14/14 are bad idea (these will not be queued on tonight's pushout of 'pu'; neither 04/14 will be). We may not be encouraging, but that is very different from deprecating the original mechanisms. The tests that depend on them to work should be kept. Otherwise, we will never know when we break them like we did at df93e33c accidenally.

If we want to have tests that exercise the equivalents spelled with the modern in-config mechanism, they should be added as new tests, not by replacing the existing ones.

Previous: Ramkumar RamachandraNext: Ramkumar Ramachandra
Message 19 of 25 in “Classify {branches,remotes}-file as fringe features”
  1. 00/14 Classify {branches,remotes}-file as fringe featuresRamkumar Ramachandra, Jun 22, 2013
  2. 01/14 t/t5505-remote: modernize styleRamkumar Ramachandra, Jun 22, 2013
  3. Junio C HamanoJun 23, 2013
  4. Ramkumar RamachandraJun 23, 2013
  5. 02/14 t/t5505-remote: test push-refspec in branches-fileRamkumar Ramachandra, Jun 22, 2013
  6. 03/14 t/t5505-remote: use test_path_is_missingRamkumar Ramachandra, Jun 22, 2013
  7. 04/14 t/t5505-remote: remove dependency on $origin_urlRamkumar Ramachandra, Jun 22, 2013
  8. 05/14 remote: remove dead code in read_branches_file()Ramkumar Ramachandra, Jun 22, 2013
  9. Junio C HamanoJun 23, 2013
  10. 06/14 t/t5505-remote: test url-with-# in branches-fileRamkumar Ramachandra, Jun 22, 2013
  11. 07/14 t/t5516-fetch-push: don't use branches-fileRamkumar Ramachandra, Jun 22, 2013
  12. 08/14 ls-remote doc: fix example invocation on git.gitRamkumar Ramachandra, Jun 22, 2013
  13. Junio C HamanoJun 23, 2013
  14. Ramkumar RamachandraJun 23, 2013
  15. Junio C HamanoJun 23, 2013
  16. 09/14 ls-remote doc: rewrite <repository> paragraphRamkumar Ramachandra, Jun 22, 2013
  17. 10/14 ls-remote doc: don't encourage use of branches-fileRamkumar Ramachandra, Jun 22, 2013
  18. 11/14 t/t5505-remote: test multiple push/pull in remotes-fileRamkumar Ramachandra, Jun 22, 2013
  19. Junio C HamanoJun 23, 2013
  20. Ramkumar RamachandraJun 23, 2013
  21. Junio C HamanoJun 23, 2013
  22. 12/14 t/t5510-fetch: don't use remotes-fileRamkumar Ramachandra, Jun 22, 2013
  23. 13/14 t/t5515-fetch-merge-logic: don't use {branches,remotes}-fileRamkumar Ramachandra, Jun 22, 2013
  24. 14/14 remote: add comment about read_{branches,remotes}_fileRamkumar Ramachandra, Jun 22, 2013
  25. Ramkumar RamachandraJun 25, 2013

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.