From 434f6a70dd43663a35d3ccd7d1e70e5d9ae77d5d Mon Sep 17 00:00:00 2001 From: Julien Duponchelle Date: Fri, 18 Nov 2016 12:08:29 +0100 Subject: [PATCH] Fix tests on Python 3.5 >= --- tests/utils/test_asyncio.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/utils/test_asyncio.py b/tests/utils/test_asyncio.py index 122a30aa..0e4e3c48 100644 --- a/tests/utils/test_asyncio.py +++ b/tests/utils/test_asyncio.py @@ -22,6 +22,7 @@ import sys from unittest.mock import MagicMock from gns3server.utils.asyncio import wait_run_in_executor, subprocess_check_output, wait_for_process_termination, locked_coroutine +from tests.utils import AsyncioMagicMock def test_wait_run_in_executor(loop): @@ -57,6 +58,9 @@ def test_subprocess_check_output(loop, tmpdir, restore_original_path): def test_wait_for_process_termination(loop): + if sys.version_info >= (3, 5): + # No need for test we use native version + return process = MagicMock() process.returncode = 0 exec = wait_for_process_termination(process)