git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johan Herland <johan@herland.net>
To: git@vger.kernel.org
Cc: johan@herland.net, gitster@pobox.com
Subject: [PATCHv2 5/8] t7201.24: Add refspec to keep --track working
Date: Sat, 20 Apr 2013 17:06:00 +0200	[thread overview]
Message-ID: <1366470363-22309-6-git-send-email-johan@herland.net> (raw)
In-Reply-To: <1366470363-22309-1-git-send-email-johan@herland.net>

We are formalizing a requirement that any remote-tracking branch to be used
as an upstream (i.e. as an argument to --track), _must_ "belong" to a
configured remote by being matched by the "dst" side of a fetch refspec.

Without this patch, this test would start failing when the new behavior is
introduced.

Signed-off-by: Johan Herland <johan@herland.net>
---
 t/t7201-co.sh | 1 +
 1 file changed, 1 insertion(+)

diff --git a/t/t7201-co.sh b/t/t7201-co.sh
index be9672e..0c9ec0a 100755
--- a/t/t7201-co.sh
+++ b/t/t7201-co.sh
@@ -431,6 +431,7 @@ test_expect_success 'detach a symbolic link HEAD' '
 
 test_expect_success \
     'checkout with --track fakes a sensible -b <name>' '
+    git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*" &&
     git update-ref refs/remotes/origin/koala/bear renamer &&
 
     git checkout --track origin/koala/bear &&
-- 
1.8.1.3.704.g33f7d4f

  parent reply	other threads:[~2013-04-20 15:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-20 15:05 [PATCHv2 0/8] Improving the search for remote-tracking branches Johan Herland
2013-04-20 15:05 ` [PATCHv2 1/8] t2024: Add tests verifying current DWIM behavior of 'git checkout <branch>' Johan Herland
2013-04-20 20:44   ` Jonathan Nieder
2013-04-20 22:53     ` Johan Herland
2013-04-20 15:05 ` [PATCHv2 2/8] t2024: Show failure to use refspec when DWIMming remote branch names Johan Herland
2013-04-20 15:05 ` [PATCHv2 3/8] checkout: Use remote refspecs when DWIMming tracking branches Johan Herland
2013-04-20 15:05 ` [PATCHv2 4/8] t3200.39: tracking setup should fail if there is no matching refspec Johan Herland
2013-04-20 15:06 ` Johan Herland [this message]
2013-04-20 15:06 ` [PATCHv2 6/8] t9114.2: Don't use --track option against "svn-remote"-tracking branches Johan Herland
2013-04-21  5:24   ` Eric Wong
2013-04-20 15:06 ` [PATCHv2 7/8] branch.c: Validate tracking branches with refspecs instead of refs/remotes/* Johan Herland
2013-04-20 15:06 ` [PATCHv2 8/8] glossary: Update and rephrase the definition of a remote-tracking branch Johan Herland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1366470363-22309-6-git-send-email-johan@herland.net \
    --to=johan@herland.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).