Patchwork [04,of,11,V2] test: use current user in the multi-user amend scenario

login
register
mail settings
Submitter Boris Feld
Date Oct. 11, 2017, 12:09 p.m.
Message ID <8447ccc2c5c91520ca75.1507723790@FB>
Download mbox | patch
Permalink /patch/24725/
State Accepted
Headers show

Comments

Boris Feld - Oct. 11, 2017, 12:09 p.m.
# HG changeset patch
# User Boris Feld <boris.feld@octobus.net>
# Date 1507530955 -7200
#      Mon Oct 09 08:35:55 2017 +0200
# Node ID 8447ccc2c5c91520ca75e6bbdc57100af8d0e931
# Parent  30f0f979da9ca8adceaba48fddfb146f5b9cea78
# EXP-Topic obsfatekeyword
# Available At https://bitbucket.org/octobus/mercurial-devel/
#              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r 8447ccc2c5c9
test: use current user in the multi-user amend scenario

The obsfate template keyword that will be introduced in a later patch
distinguish between current user and other users when displaying the obsfate
users.

Update the test before for clarity.
Yuya Nishihara - Oct. 11, 2017, 1:15 p.m.
On Wed, 11 Oct 2017 14:09:50 +0200, Boris Feld wrote:
> # HG changeset patch
> # User Boris Feld <boris.feld@octobus.net>
> # Date 1507530955 -7200
> #      Mon Oct 09 08:35:55 2017 +0200
> # Node ID 8447ccc2c5c91520ca75e6bbdc57100af8d0e931
> # Parent  30f0f979da9ca8adceaba48fddfb146f5b9cea78
> # EXP-Topic obsfatekeyword
> # Available At https://bitbucket.org/octobus/mercurial-devel/
> #              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r 8447ccc2c5c9
> test: use current user in the multi-user amend scenario

Queued up to this patch, thanks.

Patch

diff --git a/tests/test-obsmarker-template.t b/tests/test-obsmarker-template.t
--- a/tests/test-obsmarker-template.t
+++ b/tests/test-obsmarker-template.t
@@ -42,7 +42,7 @@ 
   $ mkcommit ROOT
   $ mkcommit A0
   $ echo 42 >> A0
-  $ hg commit --amend -m "A1" --config devel.default-date="1234567890 0" --config devel.user.obsmarker=test1
+  $ hg commit --amend -m "A1" --config devel.default-date="1234567890 0"
   $ hg commit --amend -m "A2" --config devel.default-date="987654321 0" --config devel.user.obsmarker=test2
 
   $ hg log --hidden -G
@@ -91,7 +91,7 @@ 
   o  d004c8f274b9
   |
   | @  471f378eab4c
-  |/     Obsfate: rewritten using amend as 3:d004c8f274b9 by test1, test2 (between 2001-04-19 04:25 +0000 and 2009-02-13 23:31 +0000);
+  |/     Obsfate: rewritten using amend as 3:d004c8f274b9 by test, test2 (between 2001-04-19 04:25 +0000 and 2009-02-13 23:31 +0000);
   o  ea207398892e
   
   $ hg up 'desc(A1)' --hidden
@@ -145,7 +145,7 @@ 
   | @  a468dc9b3633
   |/     Obsfate: rewritten using amend as 3:d004c8f274b9 by test2 (at 2001-04-19 04:25 +0000);
   | x  471f378eab4c
-  |/     Obsfate: rewritten using amend as 2:a468dc9b3633 by test1 (at 2009-02-13 23:31 +0000);
+  |/     Obsfate: rewritten using amend as 2:a468dc9b3633 by test (at 2009-02-13 23:31 +0000);
   o  ea207398892e
   
 
@@ -190,7 +190,7 @@ 
   | x  a468dc9b3633
   |/     Obsfate: rewritten using amend as 3:d004c8f274b9 by test2 (at 2001-04-19 04:25 +0000);
   | x  471f378eab4c
-  |/     Obsfate: rewritten using amend as 2:a468dc9b3633 by test1 (at 2009-02-13 23:31 +0000);
+  |/     Obsfate: rewritten using amend as 2:a468dc9b3633 by test (at 2009-02-13 23:31 +0000);
   o  ea207398892e
   
   $ hg fatelogjson --hidden
@@ -199,7 +199,7 @@ 
   | x  a468dc9b3633
   |/     Obsfate: [{"markers": [["a468dc9b36338b14fdb7825f55ce3df4e71517ad", ["d004c8f274b9ec480a47a93c10dac5eee63adb78"], 0, [["operation", "amend"], ["user", "test2"]], [987654321.0, 0], null]], "successors": ["d004c8f274b9ec480a47a93c10dac5eee63adb78"]}]
   | x  471f378eab4c
-  |/     Obsfate: [{"markers": [["471f378eab4c5e25f6c77f785b27c936efb22874", ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"], 0, [["operation", "amend"], ["user", "test1"]], [1234567890.0, 0], null]], "successors": ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"]}]
+  |/     Obsfate: [{"markers": [["471f378eab4c5e25f6c77f785b27c936efb22874", ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"], 0, [["operation", "amend"], ["user", "test"]], [1234567890.0, 0], null]], "successors": ["a468dc9b36338b14fdb7825f55ce3df4e71517ad"]}]
   o  ea207398892e
   
 Test templates with splitted commit