2012-08-14 01:11:12 +00:00
|
|
|
diff -up cpython-59223da36dec/Lib/test/test_gdb.py.fix-test_gdb-noise cpython-59223da36dec/Lib/test/test_gdb.py
|
|
|
|
--- cpython-59223da36dec/Lib/test/test_gdb.py.fix-test_gdb-noise 2012-08-07 06:10:57.000000000 -0400
|
|
|
|
+++ cpython-59223da36dec/Lib/test/test_gdb.py 2012-08-07 17:13:46.592343113 -0400
|
|
|
|
@@ -115,6 +115,15 @@ class DebuggerTests(unittest.TestCase):
|
2012-04-12 15:18:08 +00:00
|
|
|
# Generate a list of commands in gdb's language:
|
|
|
|
commands = ['set breakpoint pending yes',
|
|
|
|
'break %s' % breakpoint,
|
|
|
|
+
|
|
|
|
+ # GDB as of Fedora 17 onwards can distinguish between the
|
|
|
|
+ # value of a variable at entry vs current value:
|
|
|
|
+ # http://sourceware.org/gdb/onlinedocs/gdb/Variables.html
|
|
|
|
+ # which leads to the selftests failing with errors like this:
|
|
|
|
+ # AssertionError: 'v@entry=()' != '()'
|
|
|
|
+ # Disable this:
|
|
|
|
+ 'set print entry-values no',
|
|
|
|
+
|
|
|
|
'run']
|
|
|
|
if cmds_after_breakpoint:
|
|
|
|
commands += cmds_after_breakpoint
|
2012-08-14 01:11:12 +00:00
|
|
|
@@ -154,8 +163,16 @@ class DebuggerTests(unittest.TestCase):
|
2012-04-12 15:18:08 +00:00
|
|
|
err = err.replace("warning: Cannot initialize thread debugging"
|
|
|
|
" library: Debugger service failed\n",
|
|
|
|
'')
|
2012-08-14 01:11:12 +00:00
|
|
|
-
|
2012-04-12 15:18:08 +00:00
|
|
|
+ err = '\n'.join([line
|
|
|
|
+ for line in err.splitlines()
|
|
|
|
+ if not line.startswith('warning: Unable to open')
|
|
|
|
+ if not line.startswith('Missing separate debuginfo for')
|
|
|
|
+ if not line.startswith('Try: yum --disablerepo=')
|
|
|
|
+ # In case 'set print entry-values no' failed:
|
|
|
|
+ if not line.startswith('Undefined set print command')])
|
2012-08-14 01:11:12 +00:00
|
|
|
+
|
2012-04-12 15:18:08 +00:00
|
|
|
# Ensure no unexpected error messages:
|
|
|
|
+ self.maxDiff = None
|
|
|
|
self.assertEqual(err, '')
|
|
|
|
return out
|
2012-08-14 01:11:12 +00:00
|
|
|
|