summaryrefslogtreecommitdiff
path: root/gnu/packages/patches/python-3.8-fix-tests.patch
diff options
context:
space:
mode:
authorTanguy Le Carrour <tanguy@bioneland.org>2019-11-19 09:50:51 +0100
committerMarius Bakke <mbakke@fastmail.com>2019-11-20 00:16:51 +0100
commitaf6a9fc27622ea8a342fe18c8604f2fe64a04e68 (patch)
tree480934e5a9d67309df923b1fbe20e82a4afe0de2 /gnu/packages/patches/python-3.8-fix-tests.patch
parent3b7828cc7f938fcb369976cbe75d9c85f22583a1 (diff)
downloadguix-patches-af6a9fc27622ea8a342fe18c8604f2fe64a04e68.tar
guix-patches-af6a9fc27622ea8a342fe18c8604f2fe64a04e68.tar.gz
gnu: Add python-3.8.
* gnu/packages/python.scm (python-3.8): New public variable. [source]: Add patches to skip four tests. * gnu/packages/patches/python-3.8-search-paths.patch: New file. * gnu/packages/patches/python-3.8-fix-tests.patch: New file. Signed-off-by: Marius Bakke <mbakke@fastmail.com>
Diffstat (limited to 'gnu/packages/patches/python-3.8-fix-tests.patch')
-rw-r--r--gnu/packages/patches/python-3.8-fix-tests.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/gnu/packages/patches/python-3.8-fix-tests.patch b/gnu/packages/patches/python-3.8-fix-tests.patch
new file mode 100644
index 0000000000..4fbdd444c7
--- /dev/null
+++ b/gnu/packages/patches/python-3.8-fix-tests.patch
@@ -0,0 +1,42 @@
+diff --git a/Lib/test/_test_multiprocessing.py b/Lib/test/_test_multiprocessing.py
+index 1474624..887f8ee 100644
+--- a/Lib/test/_test_multiprocessing.py
++++ b/Lib/test/_test_multiprocessing.py
+@@ -3801,6 +3801,7 @@ class _TestSharedMemory(BaseTestCase):
+ sms.close()
+
+ @unittest.skipIf(os.name != "posix", "not feasible in non-posix platforms")
++ @unittest.skipUnless(sys.stdin.isatty(), "KeyboardInterrupts require a TTY device")
+ def test_shared_memory_SharedMemoryServer_ignores_sigint(self):
+ # bpo-36368: protect SharedMemoryManager server process from
+ # KeyboardInterrupt signals.
+diff --git a/Lib/test/test_signal.py b/Lib/test/test_signal.py
+index d41e94b..a1c15e7 100644
+--- a/Lib/test/test_signal.py
++++ b/Lib/test/test_signal.py
+@@ -78,6 +78,7 @@ class PosixTests(unittest.TestCase):
+ self.assertLess(len(s), signal.NSIG)
+
+ @unittest.skipUnless(sys.executable, "sys.executable required.")
++ @unittest.skipUnless(sys.stdin.isatty(), "KeyboardInterrupts require a TTY device")
+ def test_keyboard_interrupt_exit_code(self):
+ """KeyboardInterrupt triggers exit via SIGINT."""
+ process = subprocess.run(
+@@ -128,6 +129,7 @@ class WindowsSignalTests(unittest.TestCase):
+ signal.signal(7, handler)
+
+ @unittest.skipUnless(sys.executable, "sys.executable required.")
++ @unittest.skipUnless(sys.stdin.isatty(), "KeyboardInterrupts require a TTY device")
+ def test_keyboard_interrupt_exit_code(self):
+ """KeyboardInterrupt triggers an exit using STATUS_CONTROL_C_EXIT."""
+ # We don't test via os.kill(os.getpid(), signal.CTRL_C_EVENT) here
+@@ -1245,6 +1247,7 @@ class StressTest(unittest.TestCase):
+
+ class RaiseSignalTest(unittest.TestCase):
+
++ @unittest.skipUnless(sys.stdin.isatty(), "KeyboardInterrupts require a TTY device")
+ def test_sigint(self):
+ with self.assertRaises(KeyboardInterrupt):
+ signal.raise_signal(signal.SIGINT)
+--
+2.23.0