aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py3-pyee/fix-tests.patch
blob: 53934762d442a89b0f5c475d95333294fb4f3668 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
Upstream pull-request: https://github.com/jfhbrook/pyee/pull/69

Commit modified to not touch not-existing-in-release-tarball tox.ini

From e1928cc0484812345a87d20f88392d0dfab72c12 Mon Sep 17 00:00:00 2001
From: Joshua Holbrook <josh.holbrook@gmail.com>
Date: Tue, 5 May 2020 12:45:16 -0400
Subject: [PATCH] Tests pass on python 3.8

---
 tests/test_async.py |  7 ++++++-
 tox.ini             | 14 ++++++++++++--
 2 files changed, 18 insertions(+), 3 deletions(-)

diff --git a/tests/test_async.py b/tests/test_async.py
index 64ede82..01ec221 100644
--- a/tests/test_async.py
+++ b/tests/test_async.py
@@ -4,7 +4,12 @@
 import pytest_asyncio.plugin  # noqa
 
 from asyncio import Future, wait_for
-from concurrent.futures import TimeoutError
+
+try:
+    from asyncio.exceptions import TimeoutError
+except ImportError:
+    from concurrent.futures import TimeoutError
+
 from mock import Mock
 
 from twisted.internet.defer import ensureDeferred, succeed