remote-hg: add test for new bookmark special

From the point of view of Mercurial, this creates a new branch head, and requires a forced push. Ideally, however, we would want it to work just like in git; new branches can be pushed without problems. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Felipe Contreras committed May 24, 2013 at 21:29 UTC ad22b92a810bd793e4a357d0230beefb865e929e
1 file changed +15
contrib/remote-helpers/test-hg.sh
+15
@@ -370,4 +370,19 @@ test_expect_failure 'remote update bookmark diverge' '
370 check_bookmark hgrepo diverge "bump bookmark"
371 '
372
373 +test_expect_failure 'remote new bookmark multiple branch head' '
374 + test_when_finished "rm -rf gitrepo*" &&
375 +
376 + (
377 + git clone "hg::hgrepo" gitrepo &&
378 + cd gitrepo &&
379 + git checkout --quiet -b feature-c HEAD^ &&
380 + echo feature-c > content &&
381 + git commit -a -m feature-c &&
382 + git push --quiet origin feature-c
383 + ) &&
384 +
385 + check_bookmark hgrepo feature-c feature-c
386 +'
387 +
388 test_done