Patchwork D915: test-devel-warnings: make the test compatible with chg

login
register
mail settings
Submitter phabricator
Date Oct. 4, 2017, 5:40 p.m.
Message ID <96ab1279f4a465e30fcd4143f5b86c0a@localhost.localdomain>
Download mbox | patch
Permalink /patch/24510/
State Not Applicable
Headers show

Comments

phabricator - Oct. 4, 2017, 5:40 p.m.
singhsrb updated this revision to Diff 2425.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D915?vs=2370&id=2425

REVISION DETAIL
  https://phab.mercurial-scm.org/D915

AFFECTED FILES
  tests/test-devel-warnings.t

CHANGE DETAILS




To: singhsrb, #hg-reviewers
Cc: quark, mercurial-devel

Patch

diff --git a/tests/test-devel-warnings.t b/tests/test-devel-warnings.t
--- a/tests/test-devel-warnings.t
+++ b/tests/test-devel-warnings.t
@@ -96,9 +96,10 @@ 
   > EOF
   $ hg buggylocking
   devel-warn: "wlock" acquired after "lock" at: $TESTTMP/buggylocking.py:* (buggylocking) (glob)
+#if no-chg
   $ hg buggylocking --traceback
   devel-warn: "wlock" acquired after "lock" at:
-   */hg:* in * (glob)
+   */hg:* in <module> (glob)
    */mercurial/dispatch.py:* in run (glob)
    */mercurial/dispatch.py:* in dispatch (glob)
    */mercurial/dispatch.py:* in _runcatch (glob)
@@ -111,6 +112,43 @@ 
    */mercurial/dispatch.py:* in <lambda> (glob)
    */mercurial/util.py:* in check (glob)
    $TESTTMP/buggylocking.py:* in buggylocking (glob)
+#else
+  $ hg buggylocking --traceback
+  devel-warn: "wlock" acquired after "lock" at:
+   */hg:* in <module> (glob)
+   */mercurial/dispatch.py:* in run (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   */mercurial/commands.py:* in serve (glob)
+   */mercurial/server.py:* in runservice (glob)
+   */mercurial/commandserver.py:* in run (glob)
+   */mercurial/commandserver.py:* in _mainloop (glob)
+   */mercurial/commandserver.py:* in _runworker (glob)
+   */mercurial/commandserver.py:* in _serverequest (glob)
+   */mercurial/commandserver.py:* in serve (glob)
+   */mercurial/commandserver.py:* in serveone (glob)
+   */mercurial/chgserver.py:* in runcommand (glob)
+   */mercurial/commandserver.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   $TESTTMP/buggylocking.py:* in buggylocking (glob)
+#endif
   $ hg properlocking
   $ hg nowaitlocking
 
@@ -135,6 +173,7 @@ 
   devel-warn: foorbar is deprecated, go shopping
   (compatibility will be dropped after Mercurial-42.1337, update your code.) at: $TESTTMP/buggylocking.py:* (oldanddeprecated) (glob)
 
+#if no-chg
   $ hg oldanddeprecated --traceback
   devel-warn: foorbar is deprecated, go shopping
   (compatibility will be dropped after Mercurial-42.1337, update your code.) at:
@@ -151,6 +190,47 @@ 
    */mercurial/dispatch.py:* in <lambda> (glob)
    */mercurial/util.py:* in check (glob)
    $TESTTMP/buggylocking.py:* in oldanddeprecated (glob)
+#else
+  $ hg oldanddeprecated --traceback
+  devel-warn: foorbar is deprecated, go shopping
+  (compatibility will be dropped after Mercurial-42.1337, update your code.) at:
+   */hg:* in <module> (glob)
+   */mercurial/dispatch.py:* in run (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   */mercurial/commands.py:* in serve (glob)
+   */mercurial/server.py:* in runservice (glob)
+   */mercurial/commandserver.py:* in run (glob)
+   */mercurial/commandserver.py:* in _mainloop (glob)
+   */mercurial/commandserver.py:* in _runworker (glob)
+   */mercurial/commandserver.py:* in _serverequest (glob)
+   */mercurial/commandserver.py:* in serve (glob)
+   */mercurial/commandserver.py:* in serveone (glob)
+   */mercurial/chgserver.py:* in runcommand (glob)
+   */mercurial/commandserver.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   $TESTTMP/buggylocking.py:* in oldanddeprecated (glob)
+
+#endif
+
+#if no-chg
   $ hg blackbox -l 7
   1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated
   1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> devel-warn: foorbar is deprecated, go shopping
@@ -174,6 +254,52 @@ 
    $TESTTMP/buggylocking.py:* in oldanddeprecated (glob)
   1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated --traceback exited 0 after * seconds (glob)
   1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> blackbox -l 7
+#else
+  $ hg blackbox -l 7
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> devel-warn: foorbar is deprecated, go shopping
+  (compatibility will be dropped after Mercurial-42.1337, update your code.) at: $TESTTMP/buggylocking.py:* (oldanddeprecated) (glob)
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated exited 0 after * seconds (glob)
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated --traceback
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> devel-warn: foorbar is deprecated, go shopping
+  (compatibility will be dropped after Mercurial-42.1337, update your code.) at:
+   */hg:* in <module> (glob)
+   */mercurial/dispatch.py:* in run (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   */mercurial/commands.py:* in serve (glob)
+   */mercurial/server.py:* in runservice (glob)
+   */mercurial/commandserver.py:* in run (glob)
+   */mercurial/commandserver.py:* in _mainloop (glob)
+   */mercurial/commandserver.py:* in _runworker (glob)
+   */mercurial/commandserver.py:* in _serverequest (glob)
+   */mercurial/commandserver.py:* in serve (glob)
+   */mercurial/commandserver.py:* in serveone (glob)
+   */mercurial/chgserver.py:* in runcommand (glob)
+   */mercurial/commandserver.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in dispatch (glob)
+   */mercurial/dispatch.py:* in _runcatch (glob)
+   */mercurial/dispatch.py:* in _callcatch (glob)
+   */mercurial/scmutil.py:* in callcatch (glob)
+   */mercurial/dispatch.py:* in _runcatchfunc (glob)
+   */mercurial/dispatch.py:* in _dispatch (glob)
+   */mercurial/dispatch.py:* in runcommand (glob)
+   */mercurial/dispatch.py:* in _runcommand (glob)
+   */mercurial/dispatch.py:* in <lambda> (glob)
+   */mercurial/util.py:* in check (glob)
+   $TESTTMP/buggylocking.py:* in oldanddeprecated (glob)
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated --traceback exited 0 after * seconds (glob)
+  1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> blackbox -l 7
+
+#endif
 
 Test programming error failure: