diff options
author | Pete Wyckoff <pw@padd.com> | 2013-01-14 19:47:06 -0500 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-01-15 09:46:30 -0800 |
commit | 8c9e8b6e756cce90797e19dc64e3b51426546cf3 (patch) | |
tree | 98b4029c4be49401300478584af1d4896f46b80b /t/t9806-git-p4-options.sh | |
parent | 5a8e84cde3711076d3ad7260daa0a24ee40c8e07 (diff) | |
download | git-8c9e8b6e756cce90797e19dc64e3b51426546cf3.tar.gz git-8c9e8b6e756cce90797e19dc64e3b51426546cf3.tar.xz |
git p4: fix sync --branch when no master branch
It is legal to sync a branch with a different name than
refs/remotes/p4/master, and to do so even when master does
not exist.
Signed-off-by: Pete Wyckoff <pw@padd.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t9806-git-p4-options.sh')
-rwxr-xr-x | t/t9806-git-p4-options.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/t/t9806-git-p4-options.sh b/t/t9806-git-p4-options.sh index a51f1221e..3b0000fab 100755 --- a/t/t9806-git-p4-options.sh +++ b/t/t9806-git-p4-options.sh @@ -88,14 +88,14 @@ test_expect_success 'sync when two branches but no master should noop' ' ) ' -test_expect_failure 'sync --branch updates specified branch' ' +test_expect_success 'sync --branch updates specific branch, no detection' ' test_when_finished cleanup_git && ( cd "$git" && git init && - git p4 sync --branch=refs/remotes/p4/b1 //depot@2 && - git p4 sync --branch=refs/remotes/p4/b2 //depot@2 && - git p4 sync --branch=refs/remotes/p4/b2 && + git p4 sync --branch=b1 //depot@2 && + git p4 sync --branch=b2 //depot@2 && + git p4 sync --branch=b2 && git show -s --format=%s refs/remotes/p4/b1 >show && grep "Initial import" show && git show -s --format=%s refs/remotes/p4/b2 >show && |