]> git.ipfire.org Git - ipfire-3.x.git/blob - python/patches/00167-disable-stack-navigation-tests-when-optimized-in-test_gdb.patch
python: Update to 2.7.15
[ipfire-3.x.git] / python / patches / 00167-disable-stack-navigation-tests-when-optimized-in-test_gdb.patch
1 diff --git a/Lib/test/test_gdb.py b/Lib/test/test_gdb.py
2 index 3354b34..10ba0e5 100644
3 --- a/Lib/test/test_gdb.py
4 +++ b/Lib/test/test_gdb.py
5 @@ -725,11 +725,10 @@ class PyListTests(DebuggerTests):
6 ' 2 \n'
7 ' 3 def foo(a, b, c):\n',
8 bt)
9 -
10 +@unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
11 +@unittest.skipIf(python_is_optimized(),
12 + "Python was compiled with optimizations")
13 class StackNavigationTests(DebuggerTests):
14 - @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
15 - @unittest.skipIf(python_is_optimized(),
16 - "Python was compiled with optimizations")
17 def test_pyup_command(self):
18 'Verify that the "py-up" command works'
19 bt = self.get_stack_trace(script=self.get_sample_script(),
20 @@ -740,7 +739,6 @@ class StackNavigationTests(DebuggerTests):
21 baz\(a, b, c\)
22 $''')
23
24 - @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
25 def test_down_at_bottom(self):
26 'Verify handling of "py-down" at the bottom of the stack'
27 bt = self.get_stack_trace(script=self.get_sample_script(),
28 @@ -748,9 +746,6 @@ $''')
29 self.assertEndsWith(bt,
30 'Unable to find a newer python frame\n')
31
32 - @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
33 - @unittest.skipIf(python_is_optimized(),
34 - "Python was compiled with optimizations")
35 def test_up_at_top(self):
36 'Verify handling of "py-up" at the top of the stack'
37 bt = self.get_stack_trace(script=self.get_sample_script(),
38 @@ -758,9 +753,6 @@ $''')
39 self.assertEndsWith(bt,
40 'Unable to find an older python frame\n')
41
42 - @unittest.skipUnless(HAS_PYUP_PYDOWN, "test requires py-up/py-down commands")
43 - @unittest.skipIf(python_is_optimized(),
44 - "Python was compiled with optimizations")
45 def test_up_then_down(self):
46 'Verify "py-up" followed by "py-down"'
47 bt = self.get_stack_trace(script=self.get_sample_script(),