[PATCH 1 of 3] test-phases-exchange: properly conditionalize output

Matt Harbison mharbison72 at gmail.com
Tue Jul 18 12:51:18 UTC 2017


# HG changeset patch
# User Matt Harbison <matt_harbison at yahoo.com>
# Date 1500380050 14400
#      Tue Jul 18 08:14:10 2017 -0400
# Node ID 684787b859b507ffa4a42baf6e453f14c6eb6352
# Parent  7733525d160cbf6395d63fc8a62b56760e75b06b
test-phases-exchange: properly conditionalize output

I forgot to invert the conditions, and the test runner didn't catch it[1].  But
since only '&&' is supported in the per-line feature tests, this won't work
anyway.

[1] https://www.mercurial-scm.org/pipermail/mercurial-devel/2017-July/101941.html

diff --git a/tests/test-phases-exchange.t b/tests/test-phases-exchange.t
--- a/tests/test-phases-exchange.t
+++ b/tests/test-phases-exchange.t
@@ -1302,12 +1302,17 @@
 does.  The conditional output accounts for changes in the conditional block
 above.
 
+#if unix-permissions no-root
+  $ hg -R Upsilon phase -q --force --draft 2
+  test-debug-phase: move rev 2: 0 -> 1
+#else
   $ hg -R Upsilon phase -q --force --draft 2
   test-debug-phase: move rev 2: 0 -> 1
-  test-debug-phase: move rev 3: 0 -> 1 (unix-permissions no-root !)
-  test-debug-phase: move rev 7: 0 -> 1 (unix-permissions no-root !)
-  test-debug-phase: move rev 8: 0 -> 1 (unix-permissions no-root !)
-  test-debug-phase: move rev 9: 0 -> 1 (unix-permissions no-root !)
+  test-debug-phase: move rev 3: 0 -> 1
+  test-debug-phase: move rev 7: 0 -> 1
+  test-debug-phase: move rev 8: 0 -> 1
+  test-debug-phase: move rev 9: 0 -> 1
+#endif
 
   $ hg clone -q Upsilon Pi -r 7
   test-debug-phase: new rev 0:  x -> 0


More information about the Mercurial-devel mailing list