diff tests/test-histedit-outgoing.t @ 18995:0023a6e49268

histedit: make "hg histedit" sensitive to branch in URL Before this patch, "hg histedit" are not sensitive to the branch specified in the URL of the destination repository, even though "hg push"/"hg outgoing" are so: Invocation of "discovery.findcommonoutgoing()" without "onlyheads" argument treats revisions on branches other than the one specified in the URL as outgoing ones unexpectedly. This patch specifies list of head revisions, which are already detected by "hg.addbranchrevs()" from URL and looked up against local repository, as "onlyheads" to "discovery.findcommonoutgoing()" to limit calculation of outgoing revisions.
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Tue, 09 Apr 2013 23:40:10 +0900
parents f3a7f05f474a
children 44d7bfe08c14
line wrap: on
line diff
--- a/tests/test-histedit-outgoing.t	Tue Apr 09 23:40:10 2013 +0900
+++ b/tests/test-histedit-outgoing.t	Tue Apr 09 23:40:10 2013 +0900
@@ -82,3 +82,24 @@
   #
   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ cd ..
+
+test sensitivity to branch in URL:
+
+  $ cd r2
+  $ hg -q update 2
+  $ hg -q branch foo
+  $ hg commit -m 'create foo branch'
+  $ HGEDITOR=cat hg histedit --outgoing '../r#foo' | grep -v comparing | grep -v searching
+  pick f26599ee3441 6 create foo branch
+  
+  # Edit history between f26599ee3441 and f26599ee3441
+  #
+  # Commands:
+  #  p, pick = use commit
+  #  e, edit = use commit, but stop for amending
+  #  f, fold = use commit, but fold into previous commit (combines N and N-1)
+  #  d, drop = remove commit from history
+  #  m, mess = edit message without changing commit content
+  #
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  $ cd ..