diff tests/test-evolve-obshistory-content-divergent.t @ 5301:e8660b28bfee

obslog: makes --origin flag the default Test change have been carefully validated.
author Anton Shestakov <av6@dwimlabs.net>
date Thu, 07 May 2020 01:29:48 +0200
parents 258c0a99c5b0
children 88f9bbba392d 6ea05c9744de
line wrap: on
line diff
--- a/tests/test-evolve-obshistory-content-divergent.t	Thu May 07 01:29:24 2020 +0200
+++ b/tests/test-evolve-obshistory-content-divergent.t	Thu May 07 01:29:48 2020 +0200
@@ -79,7 +79,7 @@
 -----------
 
 Check that obslog on the divergent revision shows both destinations
-  $ hg obslog --hidden 471f378eab4c --patch
+  $ hg obslog --hidden 471f378eab4c --patch --no-origin
   x  471f378eab4c (1) A0
        reworded(description) as 65b757b745b9 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
          diff -r 471f378eab4c -r 65b757b745b9 changeset-description
@@ -102,28 +102,28 @@
 Check that with all option, every changeset is shown
   $ hg obslog --hidden --all 471f378eab4c --patch
   @  65b757b745b9 (3) A2
+  |    reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |      diff -r 471f378eab4c -r 65b757b745b9 changeset-description
+  |      --- a/changeset-description
+  |      +++ b/changeset-description
+  |      @@ -1,1 +1,1 @@
+  |      -A0
+  |      +A2
+  |
   |
   | *  fdf9bde5129a (2) A1
-  |/
+  |/     reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |        diff -r 471f378eab4c -r fdf9bde5129a changeset-description
+  |        --- a/changeset-description
+  |        +++ b/changeset-description
+  |        @@ -1,1 +1,1 @@
+  |        -A0
+  |        +A1
+  |
+  |
   x  471f378eab4c (1) A0
-       reworded(description) as 65b757b745b9 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r 65b757b745b9 changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A2
   
-       reworded(description) as fdf9bde5129a using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r fdf9bde5129a changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A1
-  
-  
-  $ hg obslog --hidden 471f378eab4c --no-graph -Tjson | python -m json.tool
+  $ hg obslog --hidden 471f378eab4c --no-graph --no-origin -Tjson | python -m json.tool
   [
       {
           "markers": [
@@ -174,9 +174,17 @@
           "shortdescription": "A0"
       }
   ]
+  $ hg obslog --hidden 471f378eab4c --no-graph -Tjson | python -m json.tool
+  [
+      {
+          "markers": [],
+          "node": "471f378eab4c5e25f6c77f785b27c936efb22874",
+          "shortdescription": "A0"
+      }
+  ]
 Check that obslog on the first diverged revision shows the revision and the
 divergent one
-  $ hg obslog fdf9bde5129a --patch
+  $ hg obslog fdf9bde5129a --patch --no-origin
   *  fdf9bde5129a (2) A1
   |
   x  471f378eab4c (1) A0
@@ -201,30 +209,30 @@
 Check that all option shows all of them
   $ hg obslog fdf9bde5129a -a --patch
   @  65b757b745b9 (3) A2
+  |    reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |      diff -r 471f378eab4c -r 65b757b745b9 changeset-description
+  |      --- a/changeset-description
+  |      +++ b/changeset-description
+  |      @@ -1,1 +1,1 @@
+  |      -A0
+  |      +A2
+  |
   |
   | *  fdf9bde5129a (2) A1
-  |/
+  |/     reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |        diff -r 471f378eab4c -r fdf9bde5129a changeset-description
+  |        --- a/changeset-description
+  |        +++ b/changeset-description
+  |        @@ -1,1 +1,1 @@
+  |        -A0
+  |        +A1
+  |
+  |
   x  471f378eab4c (1) A0
-       reworded(description) as 65b757b745b9 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r 65b757b745b9 changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A2
-  
-       reworded(description) as fdf9bde5129a using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r fdf9bde5129a changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A1
-  
   
 Check that obslog on the second diverged revision shows the revision and the
 divergent one
-  $ hg obslog 65b757b745b9 --patch
+  $ hg obslog 65b757b745b9 --patch --no-origin
   @  65b757b745b9 (3) A2
   |
   x  471f378eab4c (1) A0
@@ -248,52 +256,52 @@
 Check that all option shows all of them
   $ hg obslog 65b757b745b9 -a --patch
   @  65b757b745b9 (3) A2
+  |    reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |      diff -r 471f378eab4c -r 65b757b745b9 changeset-description
+  |      --- a/changeset-description
+  |      +++ b/changeset-description
+  |      @@ -1,1 +1,1 @@
+  |      -A0
+  |      +A2
+  |
   |
   | *  fdf9bde5129a (2) A1
-  |/
+  |/     reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |        diff -r 471f378eab4c -r fdf9bde5129a changeset-description
+  |        --- a/changeset-description
+  |        +++ b/changeset-description
+  |        @@ -1,1 +1,1 @@
+  |        -A0
+  |        +A1
+  |
+  |
   x  471f378eab4c (1) A0
-       reworded(description) as 65b757b745b9 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r 65b757b745b9 changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A2
-  
-       reworded(description) as fdf9bde5129a using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r fdf9bde5129a changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A1
-  
   
 Check that obslog on the both diverged revision shows a coherent graph
   $ hg obslog '65b757b745b9+fdf9bde5129a' --patch
   @  65b757b745b9 (3) A2
+  |    reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |      diff -r 471f378eab4c -r 65b757b745b9 changeset-description
+  |      --- a/changeset-description
+  |      +++ b/changeset-description
+  |      @@ -1,1 +1,1 @@
+  |      -A0
+  |      +A2
+  |
   |
   | *  fdf9bde5129a (2) A1
-  |/
+  |/     reworded(description) from 471f378eab4c using amend by test (Thu Jan 01 00:00:00 1970 +0000)
+  |        diff -r 471f378eab4c -r fdf9bde5129a changeset-description
+  |        --- a/changeset-description
+  |        +++ b/changeset-description
+  |        @@ -1,1 +1,1 @@
+  |        -A0
+  |        +A1
+  |
+  |
   x  471f378eab4c (1) A0
-       reworded(description) as 65b757b745b9 using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r 65b757b745b9 changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A2
   
-       reworded(description) as fdf9bde5129a using amend by test (Thu Jan 01 00:00:00 1970 +0000)
-         diff -r 471f378eab4c -r fdf9bde5129a changeset-description
-         --- a/changeset-description
-         +++ b/changeset-description
-         @@ -1,1 +1,1 @@
-         -A0
-         +A1
-  
-  
-  $ hg obslog '65b757b745b9+fdf9bde5129a' --no-graph -Tjson | python -m json.tool
+  $ hg obslog '65b757b745b9+fdf9bde5129a' --no-graph --no-origin -Tjson | python -m json.tool
   [
       {
           "markers": [],
@@ -354,6 +362,68 @@
           "shortdescription": "A1"
       }
   ]
+  $ hg obslog '65b757b745b9+fdf9bde5129a' --no-graph -Tjson | python -m json.tool
+  [
+      {
+          "markers": [
+              {
+                  "dates": [
+                      [
+                          0.0,
+                          0
+                      ]
+                  ],
+                  "effects": [
+                      "description"
+                  ],
+                  "operations": [
+                      "amend"
+                  ],
+                  "prednodes": [
+                      "471f378eab4c5e25f6c77f785b27c936efb22874"
+                  ],
+                  "users": [
+                      "test"
+                  ],
+                  "verb": "reworded"
+              }
+          ],
+          "node": "65b757b745b935093c87a2bccd877521cccffcbd",
+          "shortdescription": "A2"
+      },
+      {
+          "markers": [],
+          "node": "471f378eab4c5e25f6c77f785b27c936efb22874",
+          "shortdescription": "A0"
+      },
+      {
+          "markers": [
+              {
+                  "dates": [
+                      [
+                          *, (glob)
+                          0
+                      ]
+                  ],
+                  "effects": [
+                      "description"
+                  ],
+                  "operations": [
+                      "amend"
+                  ],
+                  "prednodes": [
+                      "471f378eab4c5e25f6c77f785b27c936efb22874"
+                  ],
+                  "users": [
+                      "test"
+                  ],
+                  "verb": "reworded"
+              }
+          ],
+          "node": "fdf9bde5129a28d4548fadd3f62b265cdd3b7a2e",
+          "shortdescription": "A1"
+      }
+  ]
   $ hg update 471f378eab4c
   abort: hidden revision '471f378eab4c' has diverged!
   (use --hidden to access hidden revisions)