changeset 6:2ec66dbe2ebe

merge
author Pierre-Yves David <pierre-yves.david@logilab.fr>
date Mon, 23 May 2011 15:02:16 +0200
parents 9445ce78a935 (diff) bc78b6b29447 (current diff)
children cc592295900f
files tests/test-private.t
diffstat 2 files changed, 9 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/states.py	Mon May 23 14:31:56 2011 +0200
+++ b/states.py	Mon May 23 15:02:16 2011 +0200
@@ -111,6 +111,7 @@
     if not repo.local():
         return
 
+    o_cancopy =repo.cancopy
     class statefulrepo(repo.__class__):
 
         def nodestate(self, node):
@@ -184,5 +185,8 @@
                     selected.add(candidate)
             return sorted(selected)
 
+        def cancopy(self):
+            return o_cancopy() and (self._publicheads == self.heads())
+
     repo.__class__ = statefulrepo
 
--- a/tests/test-private.t	Mon May 23 14:31:56 2011 +0200
+++ b/tests/test-private.t	Mon May 23 15:02:16 2011 +0200
@@ -108,6 +108,11 @@
   (run 'hg update' to get a working copy)
   $ cd ..
   $ hg clone local other2
+  requesting all changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 2 changesets with 2 changes to 1 files
   updating to branch default
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg -R other2 log --template='{rev}:{node|short}\n'