tests/test-evolve-templates.t
branchmercurial-4.0
changeset 2532 ca157d06b2dc
parent 2502 d5db7464676d
child 2596 44dd9d76afb2
equal deleted inserted replaced
2467:d517659556cf 2532:ca157d06b2dc
       
     1 This test file test the various templates for precursors and successors.
       
     2 
       
     3 Global setup
       
     4 ============
       
     5 
       
     6   $ . $TESTDIR/testlib/common.sh
       
     7   $ cat >> $HGRCPATH <<EOF
       
     8   > [ui]
       
     9   > interactive = true
       
    10   > [phases]
       
    11   > publish=False
       
    12   > [extensions]
       
    13   > evolve =
       
    14   > [alias]
       
    15   > tlog = log -G -T '{node|short}\
       
    16   >     {if(precursors, "\n  Precursors: {precursors}")}\
       
    17   >     {if(precursors, "\n  semi-colon: {join(precursors, "; ")}")}\
       
    18   >     {if(successors, "\n  Successors: {successors}")}\
       
    19   >     {if(successors, "\n  semi-colon: {join(successors, "; ")}")}\
       
    20   >     {if(successors, "\n  Fate: {obsfate_quiet}")}\n'
       
    21   > EOF
       
    22 
       
    23 Test templates on amended commit
       
    24 ================================
       
    25 
       
    26 Test setup
       
    27 ----------
       
    28 
       
    29   $ hg init $TESTTMP/templates-local-amend
       
    30   $ cd $TESTTMP/templates-local-amend
       
    31   $ mkcommit ROOT
       
    32   $ mkcommit A0
       
    33   $ echo 42 >> A0
       
    34   $ hg amend -m "A1"
       
    35   $ hg amend -m "A2"
       
    36   $ hg log --hidden -G
       
    37   @  changeset:   4:d004c8f274b9
       
    38   |  tag:         tip
       
    39   |  parent:      0:ea207398892e
       
    40   |  user:        test
       
    41   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
    42   |  summary:     A2
       
    43   |
       
    44   | x  changeset:   3:a468dc9b3633
       
    45   |/   parent:      0:ea207398892e
       
    46   |    user:        test
       
    47   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
    48   |    summary:     A1
       
    49   |
       
    50   | x  changeset:   2:f137d23bb3e1
       
    51   | |  user:        test
       
    52   | |  date:        Thu Jan 01 00:00:00 1970 +0000
       
    53   | |  summary:     temporary amend commit for 471f378eab4c
       
    54   | |
       
    55   | x  changeset:   1:471f378eab4c
       
    56   |/   user:        test
       
    57   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
    58   |    summary:     A0
       
    59   |
       
    60   o  changeset:   0:ea207398892e
       
    61      user:        test
       
    62      date:        Thu Jan 01 00:00:00 1970 +0000
       
    63      summary:     ROOT
       
    64   
       
    65 Check templates
       
    66 ---------------
       
    67   $ hg up 'desc(A0)' --hidden
       
    68   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
    69   working directory parent is obsolete! (471f378eab4c)
       
    70   (use 'hg evolve' to update to its successor: d004c8f274b9)
       
    71 
       
    72 Precursors template should show current revision as it is the working copy
       
    73   $ hg tlog
       
    74   o  d004c8f274b9
       
    75   |    Precursors: 471f378eab4c
       
    76   |    semi-colon: 471f378eab4c
       
    77   | @  471f378eab4c
       
    78   |/     Successors: [d004c8f274b9]
       
    79   |      semi-colon: [d004c8f274b9]
       
    80   |      Fate: superseed as d004c8f274b9
       
    81   o  ea207398892e
       
    82   
       
    83   $ hg up 'desc(A1)' --hidden
       
    84   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
    85   working directory parent is obsolete! (a468dc9b3633)
       
    86   (use 'hg evolve' to update to its successor: d004c8f274b9)
       
    87 
       
    88 Precursors template should show current revision as it is the working copy
       
    89   $ hg tlog
       
    90   o  d004c8f274b9
       
    91   |    Precursors: a468dc9b3633
       
    92   |    semi-colon: a468dc9b3633
       
    93   | @  a468dc9b3633
       
    94   |/     Successors: [d004c8f274b9]
       
    95   |      semi-colon: [d004c8f274b9]
       
    96   |      Fate: superseed as d004c8f274b9
       
    97   o  ea207398892e
       
    98   
       
    99 Precursors template should show the precursor as we force its display with
       
   100 --hidden  
       
   101   $ hg tlog --hidden
       
   102   o  d004c8f274b9
       
   103   |    Precursors: a468dc9b3633
       
   104   |    semi-colon: a468dc9b3633
       
   105   | @  a468dc9b3633
       
   106   |/     Precursors: 471f378eab4c
       
   107   |      semi-colon: 471f378eab4c
       
   108   |      Successors: [d004c8f274b9]
       
   109   |      semi-colon: [d004c8f274b9]
       
   110   |      Fate: superseed as d004c8f274b9
       
   111   | x  f137d23bb3e1
       
   112   | |
       
   113   | x  471f378eab4c
       
   114   |/     Successors: [a468dc9b3633]
       
   115   |      semi-colon: [a468dc9b3633]
       
   116   |      Fate: superseed as a468dc9b3633
       
   117   o  ea207398892e
       
   118   
       
   119 
       
   120   $ hg up 'desc(A2)'
       
   121   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   122   $ hg tlog
       
   123   @  d004c8f274b9
       
   124   |
       
   125   o  ea207398892e
       
   126   
       
   127   $ hg tlog --hidden
       
   128   @  d004c8f274b9
       
   129   |    Precursors: a468dc9b3633
       
   130   |    semi-colon: a468dc9b3633
       
   131   | x  a468dc9b3633
       
   132   |/     Precursors: 471f378eab4c
       
   133   |      semi-colon: 471f378eab4c
       
   134   |      Successors: [d004c8f274b9]
       
   135   |      semi-colon: [d004c8f274b9]
       
   136   |      Fate: superseed as d004c8f274b9
       
   137   | x  f137d23bb3e1
       
   138   | |
       
   139   | x  471f378eab4c
       
   140   |/     Successors: [a468dc9b3633]
       
   141   |      semi-colon: [a468dc9b3633]
       
   142   |      Fate: superseed as a468dc9b3633
       
   143   o  ea207398892e
       
   144   
       
   145 
       
   146 Test templates with splitted commit
       
   147 ===================================
       
   148 
       
   149   $ hg init $TESTTMP/templates-local-split
       
   150   $ cd $TESTTMP/templates-local-split
       
   151   $ mkcommit ROOT
       
   152   $ echo 42 >> a
       
   153   $ echo 43 >> b
       
   154   $ hg commit -A -m "A0"
       
   155   adding a
       
   156   adding b
       
   157   $ hg log --hidden -G
       
   158   @  changeset:   1:471597cad322
       
   159   |  tag:         tip
       
   160   |  user:        test
       
   161   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   162   |  summary:     A0
       
   163   |
       
   164   o  changeset:   0:ea207398892e
       
   165      user:        test
       
   166      date:        Thu Jan 01 00:00:00 1970 +0000
       
   167      summary:     ROOT
       
   168   
       
   169   $ hg split -r 'desc(A0)' -d "0 0" << EOF
       
   170   > y
       
   171   > y
       
   172   > n
       
   173   > n
       
   174   > y
       
   175   > y
       
   176   > EOF
       
   177   0 files updated, 0 files merged, 2 files removed, 0 files unresolved
       
   178   adding a
       
   179   adding b
       
   180   diff --git a/a b/a
       
   181   new file mode 100644
       
   182   examine changes to 'a'? [Ynesfdaq?] y
       
   183   
       
   184   @@ -0,0 +1,1 @@
       
   185   +42
       
   186   record change 1/2 to 'a'? [Ynesfdaq?] y
       
   187   
       
   188   diff --git a/b b/b
       
   189   new file mode 100644
       
   190   examine changes to 'b'? [Ynesfdaq?] n
       
   191   
       
   192   created new head
       
   193   Done splitting? [yN] n
       
   194   diff --git a/b b/b
       
   195   new file mode 100644
       
   196   examine changes to 'b'? [Ynesfdaq?] y
       
   197   
       
   198   @@ -0,0 +1,1 @@
       
   199   +43
       
   200   record this change to 'b'? [Ynesfdaq?] y
       
   201   
       
   202   no more change to split
       
   203 
       
   204   $ hg log --hidden -G
       
   205   @  changeset:   3:f257fde29c7a
       
   206   |  tag:         tip
       
   207   |  user:        test
       
   208   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   209   |  summary:     A0
       
   210   |
       
   211   o  changeset:   2:337fec4d2edc
       
   212   |  parent:      0:ea207398892e
       
   213   |  user:        test
       
   214   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   215   |  summary:     A0
       
   216   |
       
   217   | x  changeset:   1:471597cad322
       
   218   |/   user:        test
       
   219   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   220   |    summary:     A0
       
   221   |
       
   222   o  changeset:   0:ea207398892e
       
   223      user:        test
       
   224      date:        Thu Jan 01 00:00:00 1970 +0000
       
   225      summary:     ROOT
       
   226   
       
   227 
       
   228 Check templates
       
   229 ---------------
       
   230 
       
   231   $ hg up 'obsolete()' --hidden
       
   232   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   233   working directory parent is obsolete! (471597cad322)
       
   234   (use 'hg evolve' to update to its tipmost successor: 337fec4d2edc, f257fde29c7a)
       
   235 
       
   236 Precursors template should show current revision as it is the working copy
       
   237   $ hg tlog
       
   238   o  f257fde29c7a
       
   239   |    Precursors: 471597cad322
       
   240   |    semi-colon: 471597cad322
       
   241   o  337fec4d2edc
       
   242   |    Precursors: 471597cad322
       
   243   |    semi-colon: 471597cad322
       
   244   | @  471597cad322
       
   245   |/     Successors: [337fec4d2edc, f257fde29c7a]
       
   246   |      semi-colon: [337fec4d2edc, f257fde29c7a]
       
   247   |      Fate: superseed as 337fec4d2edc,f257fde29c7a
       
   248   o  ea207398892e
       
   249   
       
   250   $ hg up f257fde29c7a
       
   251   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   252 
       
   253 Precursors template should not show a precursor as it's not displayed in the
       
   254 log
       
   255   $ hg tlog
       
   256   @  f257fde29c7a
       
   257   |
       
   258   o  337fec4d2edc
       
   259   |
       
   260   o  ea207398892e
       
   261   
       
   262 Precursors template should show the precursor as we force its display with
       
   263 --hidden
       
   264   $ hg tlog --hidden
       
   265   @  f257fde29c7a
       
   266   |    Precursors: 471597cad322
       
   267   |    semi-colon: 471597cad322
       
   268   o  337fec4d2edc
       
   269   |    Precursors: 471597cad322
       
   270   |    semi-colon: 471597cad322
       
   271   | x  471597cad322
       
   272   |/     Successors: [337fec4d2edc, f257fde29c7a]
       
   273   |      semi-colon: [337fec4d2edc, f257fde29c7a]
       
   274   |      Fate: superseed as 337fec4d2edc,f257fde29c7a
       
   275   o  ea207398892e
       
   276   
       
   277 Test templates with folded commit
       
   278 ==============================
       
   279 
       
   280 Test setup
       
   281 ----------
       
   282 
       
   283   $ hg init $TESTTMP/templates-local-fold
       
   284   $ cd $TESTTMP/templates-local-fold
       
   285   $ mkcommit ROOT
       
   286   $ mkcommit A0
       
   287   $ mkcommit B0
       
   288   $ hg log --hidden -G
       
   289   @  changeset:   2:0dec01379d3b
       
   290   |  tag:         tip
       
   291   |  user:        test
       
   292   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   293   |  summary:     B0
       
   294   |
       
   295   o  changeset:   1:471f378eab4c
       
   296   |  user:        test
       
   297   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   298   |  summary:     A0
       
   299   |
       
   300   o  changeset:   0:ea207398892e
       
   301      user:        test
       
   302      date:        Thu Jan 01 00:00:00 1970 +0000
       
   303      summary:     ROOT
       
   304   
       
   305   $ hg fold --exact -r 'desc(A0) + desc(B0)' --date "0 0" -m "C0"
       
   306   2 changesets folded
       
   307   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   308   $ hg log --hidden -G
       
   309   @  changeset:   3:eb5a0daa2192
       
   310   |  tag:         tip
       
   311   |  parent:      0:ea207398892e
       
   312   |  user:        test
       
   313   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   314   |  summary:     C0
       
   315   |
       
   316   | x  changeset:   2:0dec01379d3b
       
   317   | |  user:        test
       
   318   | |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   319   | |  summary:     B0
       
   320   | |
       
   321   | x  changeset:   1:471f378eab4c
       
   322   |/   user:        test
       
   323   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   324   |    summary:     A0
       
   325   |
       
   326   o  changeset:   0:ea207398892e
       
   327      user:        test
       
   328      date:        Thu Jan 01 00:00:00 1970 +0000
       
   329      summary:     ROOT
       
   330   
       
   331 Check templates
       
   332 ---------------
       
   333 
       
   334   $ hg up 'desc(A0)' --hidden
       
   335   0 files updated, 0 files merged, 1 files removed, 0 files unresolved
       
   336   working directory parent is obsolete! (471f378eab4c)
       
   337   (use 'hg evolve' to update to its successor: eb5a0daa2192)
       
   338 
       
   339 Precursors template should show current revision as it is the working copy
       
   340   $ hg tlog
       
   341   o  eb5a0daa2192
       
   342   |    Precursors: 471f378eab4c
       
   343   |    semi-colon: 471f378eab4c
       
   344   | @  471f378eab4c
       
   345   |/     Successors: [eb5a0daa2192]
       
   346   |      semi-colon: [eb5a0daa2192]
       
   347   |      Fate: superseed as eb5a0daa2192
       
   348   o  ea207398892e
       
   349   
       
   350   $ hg up 'desc(B0)' --hidden
       
   351   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   352   working directory parent is obsolete! (0dec01379d3b)
       
   353   (use 'hg evolve' to update to its successor: eb5a0daa2192)
       
   354 
       
   355 Precursors template should show both precursors as they should be both
       
   356 displayed
       
   357   $ hg tlog
       
   358   o  eb5a0daa2192
       
   359   |    Precursors: 0dec01379d3b 471f378eab4c
       
   360   |    semi-colon: 0dec01379d3b; 471f378eab4c
       
   361   | @  0dec01379d3b
       
   362   | |    Successors: [eb5a0daa2192]
       
   363   | |    semi-colon: [eb5a0daa2192]
       
   364   | |    Fate: superseed as eb5a0daa2192
       
   365   | x  471f378eab4c
       
   366   |/     Successors: [eb5a0daa2192]
       
   367   |      semi-colon: [eb5a0daa2192]
       
   368   |      Fate: superseed as eb5a0daa2192
       
   369   o  ea207398892e
       
   370   
       
   371   $ hg up 'desc(C0)'
       
   372   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   373 
       
   374 Precursors template should not show precursors as it's not displayed in the
       
   375 log
       
   376   $ hg tlog
       
   377   @  eb5a0daa2192
       
   378   |
       
   379   o  ea207398892e
       
   380   
       
   381 Precursors template should show both precursors as we force its display with
       
   382 --hidden
       
   383   $ hg tlog --hidden
       
   384   @  eb5a0daa2192
       
   385   |    Precursors: 0dec01379d3b 471f378eab4c
       
   386   |    semi-colon: 0dec01379d3b; 471f378eab4c
       
   387   | x  0dec01379d3b
       
   388   | |    Successors: [eb5a0daa2192]
       
   389   | |    semi-colon: [eb5a0daa2192]
       
   390   | |    Fate: superseed as eb5a0daa2192
       
   391   | x  471f378eab4c
       
   392   |/     Successors: [eb5a0daa2192]
       
   393   |      semi-colon: [eb5a0daa2192]
       
   394   |      Fate: superseed as eb5a0daa2192
       
   395   o  ea207398892e
       
   396   
       
   397 
       
   398 Test templates with divergence
       
   399 ==============================
       
   400 
       
   401 Test setup
       
   402 ----------
       
   403 
       
   404   $ hg init $TESTTMP/templates-local-divergence
       
   405   $ cd $TESTTMP/templates-local-divergence
       
   406   $ mkcommit ROOT
       
   407   $ mkcommit A0
       
   408   $ hg amend -m "A1"
       
   409   $ hg log --hidden -G
       
   410   @  changeset:   2:fdf9bde5129a
       
   411   |  tag:         tip
       
   412   |  parent:      0:ea207398892e
       
   413   |  user:        test
       
   414   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   415   |  summary:     A1
       
   416   |
       
   417   | x  changeset:   1:471f378eab4c
       
   418   |/   user:        test
       
   419   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   420   |    summary:     A0
       
   421   |
       
   422   o  changeset:   0:ea207398892e
       
   423      user:        test
       
   424      date:        Thu Jan 01 00:00:00 1970 +0000
       
   425      summary:     ROOT
       
   426   
       
   427   $ hg update --hidden 'desc(A0)'
       
   428   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   429   working directory parent is obsolete! (471f378eab4c)
       
   430   (use 'hg evolve' to update to its successor: fdf9bde5129a)
       
   431   $ hg amend -m "A2"
       
   432   2 new divergent changesets
       
   433   $ hg log --hidden -G
       
   434   @  changeset:   3:65b757b745b9
       
   435   |  tag:         tip
       
   436   |  parent:      0:ea207398892e
       
   437   |  user:        test
       
   438   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   439   |  summary:     A2
       
   440   |
       
   441   | o  changeset:   2:fdf9bde5129a
       
   442   |/   parent:      0:ea207398892e
       
   443   |    user:        test
       
   444   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   445   |    summary:     A1
       
   446   |
       
   447   | x  changeset:   1:471f378eab4c
       
   448   |/   user:        test
       
   449   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   450   |    summary:     A0
       
   451   |
       
   452   o  changeset:   0:ea207398892e
       
   453      user:        test
       
   454      date:        Thu Jan 01 00:00:00 1970 +0000
       
   455      summary:     ROOT
       
   456   
       
   457   $ hg amend -m 'A3'
       
   458 
       
   459 Check templates
       
   460 ---------------
       
   461 
       
   462   $ hg up 'desc(A0)' --hidden
       
   463   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   464   working directory parent is obsolete! (471f378eab4c)
       
   465   (471f378eab4c has diverged, use 'hg evolve -list --divergent' to resolve the issue)
       
   466 
       
   467 Precursors template should show current revision as it is the working copy
       
   468   $ hg tlog
       
   469   o  019fadeab383
       
   470   |    Precursors: 471f378eab4c
       
   471   |    semi-colon: 471f378eab4c
       
   472   | o  fdf9bde5129a
       
   473   |/     Precursors: 471f378eab4c
       
   474   |      semi-colon: 471f378eab4c
       
   475   | @  471f378eab4c
       
   476   |/     Successors: [fdf9bde5129a], [019fadeab383]
       
   477   |      semi-colon: [fdf9bde5129a]; [019fadeab383]
       
   478   |      Fate: superseed as fdf9bde5129a + superseed as 019fadeab383
       
   479   o  ea207398892e
       
   480   
       
   481   $ hg up 'desc(A1)'
       
   482   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   483 Precursors template should not show precursors as it's not displayed in the
       
   484 log
       
   485   $ hg tlog
       
   486   o  019fadeab383
       
   487   |
       
   488   | @  fdf9bde5129a
       
   489   |/
       
   490   o  ea207398892e
       
   491   
       
   492 Precursors template should a precursor as we force its display with --hidden
       
   493   $ hg tlog --hidden
       
   494   o  019fadeab383
       
   495   |    Precursors: 65b757b745b9
       
   496   |    semi-colon: 65b757b745b9
       
   497   | x  65b757b745b9
       
   498   |/     Precursors: 471f378eab4c
       
   499   |      semi-colon: 471f378eab4c
       
   500   |      Successors: [019fadeab383]
       
   501   |      semi-colon: [019fadeab383]
       
   502   |      Fate: superseed as 019fadeab383
       
   503   | @  fdf9bde5129a
       
   504   |/     Precursors: 471f378eab4c
       
   505   |      semi-colon: 471f378eab4c
       
   506   | x  471f378eab4c
       
   507   |/     Successors: [fdf9bde5129a], [65b757b745b9]
       
   508   |      semi-colon: [fdf9bde5129a]; [65b757b745b9]
       
   509   |      Fate: superseed as fdf9bde5129a + superseed as 65b757b745b9
       
   510   o  ea207398892e
       
   511   
       
   512 Test templates with amended + folded commit
       
   513 ===========================================
       
   514 
       
   515 Test setup
       
   516 ----------
       
   517 
       
   518   $ hg init $TESTTMP/templates-local-amend-fold
       
   519   $ cd $TESTTMP/templates-local-amend-fold
       
   520   $ mkcommit ROOT
       
   521   $ mkcommit A0
       
   522   $ mkcommit B0
       
   523   $ hg amend -m "B1"
       
   524   $ hg log --hidden -G
       
   525   @  changeset:   3:b7ea6d14e664
       
   526   |  tag:         tip
       
   527   |  parent:      1:471f378eab4c
       
   528   |  user:        test
       
   529   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   530   |  summary:     B1
       
   531   |
       
   532   | x  changeset:   2:0dec01379d3b
       
   533   |/   user:        test
       
   534   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   535   |    summary:     B0
       
   536   |
       
   537   o  changeset:   1:471f378eab4c
       
   538   |  user:        test
       
   539   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   540   |  summary:     A0
       
   541   |
       
   542   o  changeset:   0:ea207398892e
       
   543      user:        test
       
   544      date:        Thu Jan 01 00:00:00 1970 +0000
       
   545      summary:     ROOT
       
   546   
       
   547   $ hg fold --exact -r 'desc(A0) + desc(B1)' --date "0 0" -m "C0"
       
   548   2 changesets folded
       
   549   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   550   $ hg log --hidden -G
       
   551   @  changeset:   4:eb5a0daa2192
       
   552   |  tag:         tip
       
   553   |  parent:      0:ea207398892e
       
   554   |  user:        test
       
   555   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   556   |  summary:     C0
       
   557   |
       
   558   | x  changeset:   3:b7ea6d14e664
       
   559   | |  parent:      1:471f378eab4c
       
   560   | |  user:        test
       
   561   | |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   562   | |  summary:     B1
       
   563   | |
       
   564   | | x  changeset:   2:0dec01379d3b
       
   565   | |/   user:        test
       
   566   | |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   567   | |    summary:     B0
       
   568   | |
       
   569   | x  changeset:   1:471f378eab4c
       
   570   |/   user:        test
       
   571   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   572   |    summary:     A0
       
   573   |
       
   574   o  changeset:   0:ea207398892e
       
   575      user:        test
       
   576      date:        Thu Jan 01 00:00:00 1970 +0000
       
   577      summary:     ROOT
       
   578   
       
   579 Check templates
       
   580 ---------------
       
   581 
       
   582   $ hg up 'desc(A0)' --hidden
       
   583   0 files updated, 0 files merged, 1 files removed, 0 files unresolved
       
   584   working directory parent is obsolete! (471f378eab4c)
       
   585   (use 'hg evolve' to update to its successor: eb5a0daa2192)
       
   586   $ hg tlog
       
   587   o  eb5a0daa2192
       
   588   |    Precursors: 471f378eab4c
       
   589   |    semi-colon: 471f378eab4c
       
   590   | @  471f378eab4c
       
   591   |/     Successors: [eb5a0daa2192]
       
   592   |      semi-colon: [eb5a0daa2192]
       
   593   |      Fate: superseed as eb5a0daa2192
       
   594   o  ea207398892e
       
   595   
       
   596   $ hg up 'desc(B0)' --hidden
       
   597   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   598   working directory parent is obsolete! (0dec01379d3b)
       
   599   (use 'hg evolve' to update to its successor: eb5a0daa2192)
       
   600   $ hg tlog
       
   601   o  eb5a0daa2192
       
   602   |    Precursors: 0dec01379d3b 471f378eab4c
       
   603   |    semi-colon: 0dec01379d3b; 471f378eab4c
       
   604   | @  0dec01379d3b
       
   605   | |    Successors: [eb5a0daa2192]
       
   606   | |    semi-colon: [eb5a0daa2192]
       
   607   | |    Fate: superseed as eb5a0daa2192
       
   608   | x  471f378eab4c
       
   609   |/     Successors: [eb5a0daa2192]
       
   610   |      semi-colon: [eb5a0daa2192]
       
   611   |      Fate: superseed as eb5a0daa2192
       
   612   o  ea207398892e
       
   613   
       
   614   $ hg up 'desc(B1)' --hidden
       
   615   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   616   working directory parent is obsolete! (b7ea6d14e664)
       
   617   (use 'hg evolve' to update to its successor: eb5a0daa2192)
       
   618   $ hg tlog
       
   619   o  eb5a0daa2192
       
   620   |    Precursors: 471f378eab4c b7ea6d14e664
       
   621   |    semi-colon: 471f378eab4c; b7ea6d14e664
       
   622   | @  b7ea6d14e664
       
   623   | |    Successors: [eb5a0daa2192]
       
   624   | |    semi-colon: [eb5a0daa2192]
       
   625   | |    Fate: superseed as eb5a0daa2192
       
   626   | x  471f378eab4c
       
   627   |/     Successors: [eb5a0daa2192]
       
   628   |      semi-colon: [eb5a0daa2192]
       
   629   |      Fate: superseed as eb5a0daa2192
       
   630   o  ea207398892e
       
   631   
       
   632   $ hg up 'desc(C0)'
       
   633   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   634   $ hg tlog
       
   635   @  eb5a0daa2192
       
   636   |
       
   637   o  ea207398892e
       
   638   
       
   639   $ hg tlog --hidden
       
   640   @  eb5a0daa2192
       
   641   |    Precursors: 471f378eab4c b7ea6d14e664
       
   642   |    semi-colon: 471f378eab4c; b7ea6d14e664
       
   643   | x  b7ea6d14e664
       
   644   | |    Precursors: 0dec01379d3b
       
   645   | |    semi-colon: 0dec01379d3b
       
   646   | |    Successors: [eb5a0daa2192]
       
   647   | |    semi-colon: [eb5a0daa2192]
       
   648   | |    Fate: superseed as eb5a0daa2192
       
   649   | | x  0dec01379d3b
       
   650   | |/     Successors: [b7ea6d14e664]
       
   651   | |      semi-colon: [b7ea6d14e664]
       
   652   | |      Fate: superseed as b7ea6d14e664
       
   653   | x  471f378eab4c
       
   654   |/     Successors: [eb5a0daa2192]
       
   655   |      semi-colon: [eb5a0daa2192]
       
   656   |      Fate: superseed as eb5a0daa2192
       
   657   o  ea207398892e
       
   658   
       
   659 
       
   660 Test template with pushed and pulled obs markers
       
   661 ==============================================
       
   662 
       
   663 Test setup
       
   664 ----------
       
   665 
       
   666   $ hg init $TESTTMP/templates-local-remote-markers-1
       
   667   $ cd $TESTTMP/templates-local-remote-markers-1
       
   668   $ mkcommit ROOT
       
   669   $ mkcommit A0  
       
   670   $ hg clone $TESTTMP/templates-local-remote-markers-1 $TESTTMP/templates-local-remote-markers-2
       
   671   updating to branch default
       
   672   2 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   673   $ cd $TESTTMP/templates-local-remote-markers-2
       
   674   $ hg log --hidden -G
       
   675   @  changeset:   1:471f378eab4c
       
   676   |  tag:         tip
       
   677   |  user:        test
       
   678   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   679   |  summary:     A0
       
   680   |
       
   681   o  changeset:   0:ea207398892e
       
   682      user:        test
       
   683      date:        Thu Jan 01 00:00:00 1970 +0000
       
   684      summary:     ROOT
       
   685   
       
   686   $ cd $TESTTMP/templates-local-remote-markers-1
       
   687   $ hg amend -m "A1"
       
   688   $ hg amend -m "A2"
       
   689   $ hg log --hidden -G
       
   690   @  changeset:   3:7a230b46bf61
       
   691   |  tag:         tip
       
   692   |  parent:      0:ea207398892e
       
   693   |  user:        test
       
   694   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   695   |  summary:     A2
       
   696   |
       
   697   | x  changeset:   2:fdf9bde5129a
       
   698   |/   parent:      0:ea207398892e
       
   699   |    user:        test
       
   700   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   701   |    summary:     A1
       
   702   |
       
   703   | x  changeset:   1:471f378eab4c
       
   704   |/   user:        test
       
   705   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   706   |    summary:     A0
       
   707   |
       
   708   o  changeset:   0:ea207398892e
       
   709      user:        test
       
   710      date:        Thu Jan 01 00:00:00 1970 +0000
       
   711      summary:     ROOT
       
   712   
       
   713   $ cd $TESTTMP/templates-local-remote-markers-2
       
   714   $ hg pull
       
   715   pulling from $TESTTMP/templates-local-remote-markers-1
       
   716   searching for changes
       
   717   adding changesets
       
   718   adding manifests
       
   719   adding file changes
       
   720   added 1 changesets with 0 changes to 1 files (+1 heads)
       
   721   2 new obsolescence markers
       
   722   (run 'hg heads' to see heads, 'hg merge' to merge)
       
   723   working directory parent is obsolete! (471f378eab4c)
       
   724   (use 'hg evolve' to update to its successor: 7a230b46bf61)
       
   725   $ hg log --hidden -G
       
   726   o  changeset:   2:7a230b46bf61
       
   727   |  tag:         tip
       
   728   |  parent:      0:ea207398892e
       
   729   |  user:        test
       
   730   |  date:        Thu Jan 01 00:00:00 1970 +0000
       
   731   |  summary:     A2
       
   732   |
       
   733   | @  changeset:   1:471f378eab4c
       
   734   |/   user:        test
       
   735   |    date:        Thu Jan 01 00:00:00 1970 +0000
       
   736   |    summary:     A0
       
   737   |
       
   738   o  changeset:   0:ea207398892e
       
   739      user:        test
       
   740      date:        Thu Jan 01 00:00:00 1970 +0000
       
   741      summary:     ROOT
       
   742   
       
   743 
       
   744 Check templates
       
   745 ---------------
       
   746 
       
   747   $ hg tlog
       
   748   o  7a230b46bf61
       
   749   |    Precursors: 471f378eab4c
       
   750   |    semi-colon: 471f378eab4c
       
   751   | @  471f378eab4c
       
   752   |/     Successors: [7a230b46bf61]
       
   753   |      semi-colon: [7a230b46bf61]
       
   754   |      Fate: superseed as 7a230b46bf61
       
   755   o  ea207398892e
       
   756   
       
   757   $ hg up 'desc(A2)'
       
   758   0 files updated, 0 files merged, 0 files removed, 0 files unresolved
       
   759   $ hg tlog
       
   760   @  7a230b46bf61
       
   761   |
       
   762   o  ea207398892e
       
   763   
       
   764   $ hg tlog --hidden
       
   765   @  7a230b46bf61
       
   766   |    Precursors: 471f378eab4c
       
   767   |    semi-colon: 471f378eab4c
       
   768   | x  471f378eab4c
       
   769   |/     Successors: [7a230b46bf61]
       
   770   |      semi-colon: [7a230b46bf61]
       
   771   |      Fate: superseed as 7a230b46bf61
       
   772   o  ea207398892e
       
   773