summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2022-03-17 09:00:56 (GMT)
committerGitHub <noreply@github.com>2022-03-17 09:00:56 (GMT)
commit7aeb06f78ee4abba64ca2c5c7a848fd2616da6fb (patch)
tree54376f8d2541a411030c5bd8cf604829b61d0d4b
parent15df8f8d89a0e563bdd15e4cd6734298736a5a1d (diff)
downloadcpython-7aeb06f78ee4abba64ca2c5c7a848fd2616da6fb.zip
cpython-7aeb06f78ee4abba64ca2c5c7a848fd2616da6fb.tar.gz
cpython-7aeb06f78ee4abba64ca2c5c7a848fd2616da6fb.tar.bz2
Do not run test_gdb when gdb embeds Python 2. (GH-31956)
-rw-r--r--Lib/test/test_gdb.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/test/test_gdb.py b/Lib/test/test_gdb.py
index 344fd3d..0f39b8f 100644
--- a/Lib/test/test_gdb.py
+++ b/Lib/test/test_gdb.py
@@ -117,6 +117,9 @@ gdbpy_version, _ = run_gdb("--eval-command=python import sys; print(sys.version_
if not gdbpy_version:
raise unittest.SkipTest("gdb not built with embedded python support")
+if "major=2" in gdbpy_version:
+ raise unittest.SkipTest("gdb built with Python 2")
+
# Verify that "gdb" can load our custom hooks, as OS security settings may
# disallow this without a customized .gdbinit.
_, gdbpy_errors = run_gdb('--args', sys.executable)