14
0
Files
python-typing_extensions/test-sys-executable.patch

38 lines
2.2 KiB
Diff
Raw Normal View History

From 1f49677868a60ed697b0eafb2fb56471233b4ea5 Mon Sep 17 00:00:00 2001
From: "Michael R. Crusoe" <1330696+mr-c@users.noreply.github.com>
Date: Thu, 14 Feb 2019 12:25:27 +0200
Subject: [PATCH] Run the tests using the current Python executable (#615)
Not whatever "python" might be.
---
typing_extensions/src_py2/test_typing_extensions.py | 3 ++-
typing_extensions/src_py3/test_typing_extensions.py | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff -ru typing_extensions-3.7.2-orig/src_py2/test_typing_extensions.py typing_extensions-3.7.2/src_py2/test_typing_extensions.py
--- typing_extensions-3.7.2-orig/src_py2/test_typing_extensions.py 2019-01-12 22:58:29.000000000 +0700
+++ typing_extensions-3.7.2/src_py2/test_typing_extensions.py 2019-03-02 09:04:22.076991388 +0700
@@ -860,7 +860,8 @@
file_path = os.path.join(os.path.dirname(os.path.realpath(__file__)),
'typing_extensions.py')
try:
- subprocess.check_output('python -OO {}'.format(file_path),
+ subprocess.check_output('{} -OO {}'.format(sys.executable,
+ file_path),
stderr=subprocess.STDOUT,
shell=True)
except subprocess.CalledProcessError:
diff -ru typing_extensions-3.7.2-orig/src_py3/test_typing_extensions.py typing_extensions-3.7.2/src_py3/test_typing_extensions.py
--- typing_extensions-3.7.2-orig/src_py3/test_typing_extensions.py 2019-01-12 22:58:30.000000000 +0700
+++ typing_extensions-3.7.2/src_py3/test_typing_extensions.py 2019-03-02 09:04:28.645047489 +0700
@@ -1389,7 +1389,8 @@
file_path = os.path.join(os.path.dirname(os.path.realpath(__file__)),
'typing_extensions.py')
try:
- subprocess.check_output('python -OO {}'.format(file_path),
+ subprocess.check_output('{} -OO {}'.format(sys.executable,
+ file_path),
stderr=subprocess.STDOUT,
shell=True)
except subprocess.CalledProcessError: