tests/test-topic-debugcb.t
changeset 2905 610d06bcd714
parent 2904 4ae89b5834e6
child 2909 9ce092b17530
--- a/tests/test-topic-debugcb.t	Fri Sep 01 16:51:49 2017 +0200
+++ b/tests/test-topic-debugcb.t	Fri Sep 01 17:04:21 2017 +0200
@@ -19,6 +19,7 @@
   $ cd repo
   $ echo "Hello" > root
   $ hg commit -Aqm "root"
+  $ hg phase --public .
   $ echo "Hello" > a
   $ hg commit -Aqm "First commit"
   $ echo "Hello" > b
@@ -157,6 +158,7 @@
   $ cd setup1
   $ echo "Hello" > root
   $ hg commit -Aqm "root"
+  $ hg phase --public .
   $ echo "Hello" > A
   $ hg commit -Aqm "A"
   $ echo "Hello" > B
@@ -218,6 +220,7 @@
   $ cd setup2
   $ echo "Hello" > root
   $ hg commit -Aqm "root"
+  $ hg phase --public .
   $ echo "Hello" > A
   $ hg commit -Aqm "A"
   $ hg phase --public .
@@ -265,3 +268,44 @@
   |
   o  [0:249055fcca50] root
   
+
+Check that phase are properly take in account
+---------------------------------------------
+
+(we reuse above test, taking advantage of a small bug regarding stacked bookmarks. we can fuse the two tests once that bug is fixed)
+
+  $ cd ..
+  $ hg init setup-phases
+  $ cd setup-phases
+  $ echo "Hello" > root
+  $ hg commit -Aqm "root"
+  $ hg phase --public .
+  $ echo "Hello" > A
+  $ hg commit -Aqm "A"
+  $ echo "Hello" > B
+  $ hg commit -Aqm "B"
+  $ echo "Hello" > C
+  $ hg commit -Aqm "C"
+  $ hg bookmark -r . bar
+  $ hg log -G
+  @  [3:ac05e0d05d00] C
+  |    bookmark: bar
+  o  [2:10f317d09e78] B
+  |
+  o  [1:e34122c9a2bf] A
+  |
+  o  [0:249055fcca50] root
+  
+
+  $ hg debugconvertbookmark --all
+  switching to topic bar
+  changed topic to "bar" on 3 revisions
+  $ hg log -G
+  @  [6:863c43a7951c] C
+  |    topic: bar
+  o  [5:ac7f12ac947f] B
+  |    topic: bar
+  o  [4:fc82c8c14b4c] A
+  |    topic: bar
+  o  [0:249055fcca50] root
+