summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFedora Python maintainers <python-devel@lists.fedoraproject.org>2020-07-15 13:40:37 (GMT)
committerPetr Viktorin <pviktori@redhat.com>2020-09-29 13:59:05 (GMT)
commit6c034a5e546599ddc346bf495a09a4c8dbfdb4ec (patch)
treebacf38f68a3ac1856a7cf28b5ff5ab2546d27be0
parent59fcc40a1023230fe9e5bf4189a68c30953e6b72 (diff)
downloadcpython-6c034a5e546599ddc346bf495a09a4c8dbfdb4ec.zip
cpython-6c034a5e546599ddc346bf495a09a4c8dbfdb4ec.tar.gz
cpython-6c034a5e546599ddc346bf495a09a4c8dbfdb4ec.tar.bz2
00167-disable-stack-navigation-tests-when-optimized-in-test_gdb.patch
00167 # Don't run any of the stack navigation tests in test_gdb when Python is optimized, since there appear to be many different ways in which gdb can fail to read the PyFrameObject* for arbitrary places in the callstack, presumably due to compiler optimization (rhbz#912025) Not yet sent upstream
-rw-r--r--Lib/test/test_gdb.py14
1 files changed, 3 insertions, 11 deletions
diff --git a/Lib/test/test_gdb.py b/Lib/test/test_gdb.py
index 360bad1..b2bbe77 100644
--- a/Lib/test/test_gdb.py
+++ b/Lib/test/test_gdb.py
@@ -728,11 +728,10 @@ class PyListTests(DebuggerTests):
' 2 \n'
' 3 def foo(a, b, c):\n',
bt)
-
+@unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
+@unittest.skipIf(python_is_optimized(),
+ "Python was compiled with optimizations")
class StackNavigationTests(DebuggerTests):
- @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
- @unittest.skipIf(python_is_optimized(),
- "Python was compiled with optimizations")
def test_pyup_command(self):
'Verify that the "py-up" command works'
bt = self.get_stack_trace(script=self.get_sample_script(),
@@ -743,7 +742,6 @@ class StackNavigationTests(DebuggerTests):
baz\(a, b, c\)
$''')
- @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
def test_down_at_bottom(self):
'Verify handling of "py-down" at the bottom of the stack'
bt = self.get_stack_trace(script=self.get_sample_script(),
@@ -751,9 +749,6 @@ $''')
self.assertEndsWith(bt,
'Unable to find a newer python frame\n')
- @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
- @unittest.skipIf(python_is_optimized(),
- "Python was compiled with optimizations")
def test_up_at_top(self):
'Verify handling of "py-up" at the top of the stack'
bt = self.get_stack_trace(script=self.get_sample_script(),
@@ -761,9 +756,6 @@ $''')
self.assertEndsWith(bt,
'Unable to find an older python frame\n')
- @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
- @unittest.skipIf(python_is_optimized(),
- "Python was compiled with optimizations")
def test_up_then_down(self):
'Verify "py-up" followed by "py-down"'
bt = self.get_stack_trace(script=self.get_sample_script(),