[PATCH 4 of 4] test-subrepo-missing: test updating parent repo with missing subrepo revision
Angel Ezquerra
angel.ezquerra at gmail.com
Mon Nov 25 14:46:50 CST 2013
# HG changeset patch
# User Angel Ezquerra <angel.ezquerra at gmail.com>
# Date 1385410402 -3600
# Mon Nov 25 21:13:22 2013 +0100
# Node ID b7dde04337cb6dced4f212756e789391f1dfd6c0
# Parent 744f6a7b25cd7ea810ddcce3724ed82108706d5c
test-subrepo-missing: test updating parent repo with missing subrepo revision
diff --git a/tests/test-subrepo-missing.t b/tests/test-subrepo-missing.t
--- a/tests/test-subrepo-missing.t
+++ b/tests/test-subrepo-missing.t
@@ -68,4 +68,36 @@
$ ls subrepo
a
+Enable obsolete
+
+ $ cat > ${TESTTMP}/obs.py << EOF
+ > import mercurial.obsolete
+ > mercurial.obsolete._enabled = True
+ > EOF
+ $ cat >> $HGRCPATH << EOF
+ > [ui]
+ > logtemplate= {rev}:{node|short} {desc|firstline}
+ > [phases]
+ > publish=False
+ > [extensions]'
+ > obs=${TESTTMP}/obs.py
+ > EOF
+
+check that we can update parent repo with missing (amended) subrepo revision
+
+ $ hg up --repository subrepo -r tip
+ 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+ $ hg ci -m "updated subrepo to tip"
+ created new head
+ $ cd subrepo
+ $ hg update -r tip
+ 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+ $ echo foo > a
+ $ hg commit --amend -m "addb (amended)"
$ cd ..
+ $ hg update --clean .
+ target revision (102a90ea7b4a) in subrepo subrepo is hidden
+ do you want to update to it anyway (Yn)? y
+ 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+
+ $ cd ..
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hg-2.4-4.patch
Type: text/x-patch
Size: 1467 bytes
Desc: not available
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20131125/910963d6/attachment.bin>
More information about the Mercurial-devel
mailing list