[PATCH] hook: filter out unstable output in tests

Siddharth Agarwal sid0 at fb.com
Wed Mar 9 19:17:42 EST 2016


# HG changeset patch
# User Siddharth Agarwal <sid0 at fb.com>
# Date 1457568912 28800
#      Wed Mar 09 16:15:12 2016 -0800
# Node ID f131963e13d6fec5d51cafd479d530c814f61cd3
# Parent  1c658391b22fb4d98ccfb60c0e57315b55634117
# Available At http://42.netv6.net/sid0-wip/hg/
#              hg pull http://42.netv6.net/sid0-wip/hg/ -r f131963e13d6
hook: filter out unstable output in tests

This output is different between Python 2.6 and Python 2.7. It's also pretty
irrelevant, so just filter it out.

diff --git a/tests/test-hook.t b/tests/test-hook.t
--- a/tests/test-hook.t
+++ b/tests/test-hook.t
@@ -530,13 +530,11 @@ test python hooks
   (run with --traceback for stack trace)
   [255]
 
-  $ hg pull ../a --traceback 2>&1 | egrep -v '^( +File|    [_a-zA-Z*(])'
+  $ hg pull ../a --traceback 2>&1 | egrep -v '^( +File|    [_a-zA-Z*(])' | egrep -v '^( )+(\^)?$'
   pulling from ../a
   searching for changes
   exception from first failed import attempt:
   Traceback (most recent call last):
-      
-      ^
   SyntaxError: invalid syntax
   exception from second failed import attempt:
   Traceback (most recent call last):


More information about the Mercurial-devel mailing list