tests/test-phases-exchange.t
branchstable
changeset 19097 3f5e75c22585
parent 17565 f62ed3d90377
child 19116 dfb514836b78
--- a/tests/test-phases-exchange.t	Tue Apr 30 10:51:25 2013 +0200
+++ b/tests/test-phases-exchange.t	Tue Apr 30 21:19:56 2013 +0200
@@ -1062,5 +1062,43 @@
   |
   o  0 public a-A - 054250a37db4
   
+
+Pushing From an unlockable repo
+--------------------------------
+(issue3684)
+
+Unability to lock the source repo should not prevent the push. It will prevent
+the retrieval of remote phase during push. For example, pushing to a publishing
+server won't turn changeset public.
+
+1. Test that push is not prevented
+
+  $ hg init Phi
+  $ cd Upsilon
+  $ chmod -R -w .hg
+  $ hg push ../Phi
+  pushing to ../Phi
+  searching for changes
+  adding changesets
+  adding manifests
+  adding file changes
+  added 14 changesets with 14 changes to 14 files (+3 heads)
+  $ chmod -R +w .hg
+
+2. Test that failed phases movement are reported
+
+  $ hg phase --force --draft 3
+  $ chmod -R -w .hg
+  $ hg push ../Phi
+  pushing to ../Phi
+  searching for changes
+  no changes found
+  cannot lock source repo, skipping local public phase update
+  [1]
+  $ chmod -R +w .hg
+  $ hgph Upsilon
+
+  $ cd ..
+
   $ "$TESTDIR/killdaemons.py" $DAEMON_PIDS