LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File 0013-Remove-backwards-compatibility-from-tests.patch of Package mycroft-core (Project home:alarrosa:packages)

From fcc147a60d5c52d1b658c5b241e264f46c363246 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=85ke=20Forslund?= <ake.forslund@gmail.com>
Date: Mon, 12 Feb 2018 21:26:15 +0100
Subject: [PATCH 13/13] Remove backwards compatibility from tests

---
 test/unittests/client/audio_consumer_test.py | 6 +-----
 test/unittests/skills/core.py                | 3 ---
 2 files changed, 1 insertion(+), 8 deletions(-)

diff --git a/test/unittests/client/audio_consumer_test.py b/test/unittests/client/audio_consumer_test.py
index 18a22e1..9502c00 100644
--- a/test/unittests/client/audio_consumer_test.py
+++ b/test/unittests/client/audio_consumer_test.py
@@ -20,11 +20,7 @@ from speech_recognition import WavFile, AudioData
 
 from mycroft.client.speech.listener import AudioConsumer, RecognizerLoop
 from mycroft.stt import MycroftSTT
-import sys
-if sys.version_info[0] < 3:
-    from Queue import Queue
-else:
-    from queue import Queue
+from queue import Queue
 
 
 class MockRecognizer(object):
diff --git a/test/unittests/skills/core.py b/test/unittests/skills/core.py
index e9fb06c..3ef601d 100644
--- a/test/unittests/skills/core.py
+++ b/test/unittests/skills/core.py
@@ -27,9 +27,6 @@ from mycroft.skills.core import load_regex_from_file, load_regex, \
 from mycroft.skills.core import MycroftSkill, load_skill, \
     create_skill_descriptor, open_intent_envelope
 
-if sys.version_info[0] >= 3:
-    basestring = str
-
 
 class MockEmitter(object):
     def __init__(self):
-- 
2.16.2