clone: activate @ bookmark if updating to it
The message "updating bookmark @ failed!" in test-bookmarks-pushpull.t
is correct, because the changeset that the @ bookmark points to is not
pushed to the target repository.
--- a/mercurial/hg.py Fri Oct 26 13:20:44 2012 +0200
+++ b/mercurial/hg.py Fri Oct 26 14:37:03 2012 +0200
@@ -418,6 +418,7 @@
if uprev is None:
try:
uprev = destrepo._bookmarks['@']
+ update = '@'
except KeyError:
try:
uprev = destrepo.branchtip('default')
--- a/tests/test-bookmarks-pushpull.t Fri Oct 26 13:20:44 2012 +0200
+++ b/tests/test-bookmarks-pushpull.t Fri Oct 26 14:37:03 2012 +0200
@@ -338,7 +338,7 @@
updating to branch default
2 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg -R cloned-bookmarks bookmarks
- @ 1:9b140be10808
+ * @ 1:9b140be10808
X 1:9b140be10808
Y 4:c922c0139ca0
Z 2:0d2164f0ce0d
@@ -377,6 +377,7 @@
remote: adding manifests
remote: adding file changes
remote: added 1 changesets with 1 changes to 1 files
+ updating bookmark @ failed!
exporting bookmark add-foo
$ cd ..
--- a/tests/test-bookmarks.t Fri Oct 26 13:20:44 2012 +0200
+++ b/tests/test-bookmarks.t Fri Oct 26 14:37:03 2012 +0200
@@ -366,7 +366,7 @@
updating to branch default
2 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg -R cloned-bookmarks bookmarks
- @ 2:db815d6d32e6
+ * @ 2:db815d6d32e6
X2 1:925d80f479bb
Y 2:db815d6d32e6
Z 2:db815d6d32e6
@@ -384,7 +384,7 @@
updating to branch default
2 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ hg -R cloned-bookmarks-pull bookmarks
- @ 2:db815d6d32e6
+ * @ 2:db815d6d32e6
X2 1:925d80f479bb
Y 2:db815d6d32e6
Z 2:db815d6d32e6