summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2017-02-01 16:00:32 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2017-02-01 16:00:32 (GMT)
commitf94b68a025e9b35d5b612d815818b4e9e1c55fcc (patch)
tree70bfe9d35d6f81304e989c33b2298f3492ed7ce5
parent611083331d534481ca7956a376e38fb0e9ef3854 (diff)
downloadcpython-f94b68a025e9b35d5b612d815818b4e9e1c55fcc.zip
cpython-f94b68a025e9b35d5b612d815818b4e9e1c55fcc.tar.gz
cpython-f94b68a025e9b35d5b612d815818b4e9e1c55fcc.tar.bz2
Make test_gdb.test_wrapper_call() make reliable
Issue #29367. Use two break points to prevent breakpoint during Python initialization.
-rw-r--r--Lib/test/test_gdb.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/Lib/test/test_gdb.py b/Lib/test/test_gdb.py
index 247c3ad..681a1ee 100644
--- a/Lib/test/test_gdb.py
+++ b/Lib/test/test_gdb.py
@@ -856,13 +856,12 @@ id(42)
def __init__(self):
super().__init__() # wrapper_call()
+ id("first break point")
l = MyList()
''')
# Verify with "py-bt":
gdb_output = self.get_stack_trace(cmd,
- breakpoint='wrapper_call',
- cmds_after_breakpoint=['py-bt'],
- )
+ cmds_after_breakpoint=['break wrapper_call', 'continue', 'py-bt'])
self.assertIn("<method-wrapper '__init__' of MyList object at ",
gdb_output)