From 786e2d78caac0c7db9873f69d4a2899986587341 Mon Sep 17 00:00:00 2001 From: Stefano Rivera Date: Sat, 27 Dec 2025 11:16:49 -0400 Subject: [PATCH] Allow test_kernprof_sys_restoration to match python3.XX binaries Allows tests to pass on Debian package builds where multiple Python 3 versions may be supported at the same time. From: https://bugs.debian.org/1122001 --- tests/test_kernprof.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_kernprof.py b/tests/test_kernprof.py index ef67e130..f8ac4678 100644 --- a/tests/test_kernprof.py +++ b/tests/test_kernprof.py @@ -242,7 +242,7 @@ def main(): {'^Output to stdout': True, r"^Wrote .* '.*script\.py\.lprof'": True, r'^Inspect results with:''\n' - r'python -m line_profiler .*script\.py\.lprof': True, + r'\S*python\S* -m line_profiler .*script\.py\.lprof': True, r'line_profiler\.autoprofile\.autoprofile' r'\.run\(\n(?:.+,\n)*.*\)': False, r'^\[kernprof .*\]': False, @@ -252,7 +252,7 @@ def main(): {'^Output to stdout': True, r"^Wrote .* '.*script\.py\.lprof'": True, r'^Inspect results with:''\n' - r'python -m line_profiler .*script\.py\.lprof': False, + r'\S*python\S* -m line_profiler .*script\.py\.lprof': False, r'line_profiler\.autoprofile\.autoprofile' r'\.run\(\n(?:.+,\n)*.*\)': False, r'^\[kernprof .*\]': False, @@ -262,7 +262,7 @@ def main(): {'^Output to stdout': True, r"^\[kernprof .*\] Wrote .* '.*script\.py\.lprof'": True, r'Inspect results with:''\n' - r'python -m line_profiler .*script\.py\.lprof': False, + r'\S*python\S* -m line_profiler .*script\.py\.lprof': False, r'line_profiler\.autoprofile\.autoprofile' r'\.run\(\n(?:.+,\n)*.*\)': True, r'^Function: main': True},