summaryrefslogtreecommitdiff
path: root/client/test.py
diff options
context:
space:
mode:
authorschneefux <schneefux+commit@schneefux.xyz>2014-07-26 17:00:39 -0700
committerschneefux <schneefux+commit@schneefux.xyz>2014-07-26 17:00:39 -0700
commit44c9bacf3b3ef24a0f0ef971db45f145b54ff77c (patch)
treef52e264fb7c89e16470e9324b4cfce03c5881d3d /client/test.py
parent50057bec57447247846d615865fe225ffc814771 (diff)
downloadjasper-client-44c9bacf3b3ef24a0f0ef971db45f145b54ff77c.tar.gz
jasper-client-44c9bacf3b3ef24a0f0ef971db45f145b54ff77c.zip
Fixing unit tests.
Diffstat (limited to 'client/test.py')
-rw-r--r--client/test.py10
1 files changed, 6 insertions, 4 deletions
diff --git a/client/test.py b/client/test.py
index fb7d147..69567bb 100644
--- a/client/test.py
+++ b/client/test.py
@@ -29,17 +29,19 @@ class TestMic(unittest.TestCase):
self.time_clip = "../static/audio/time.wav"
from mic import Mic
- self.m = Mic(speaker.newSpeaker(), "languagemodel.lm", "dictionary.dic",
- "languagemodel_persona.lm", "dictionary_persona.dic")
+ from stt import PocketSphinxSTT
+
+ self.stt = PocketSphinxSTT()
def testTranscribeJasper(self):
"""Does Jasper recognize his name (i.e., passive listen)?"""
- transcription = self.m.transcribe(self.jasper_clip, PERSONA_ONLY=True)
+ transcription = self.stt.transcribe(self.jasper_clip, PERSONA_ONLY=True)
self.assertTrue("JASPER" in transcription)
def testTranscribe(self):
"""Does Jasper recognize 'time' (i.e., active listen)?"""
- transcription = self.m.transcribe(self.time_clip)
+ transcription = self.stt.transcribe(self.time_clip)
+ print transcription
self.assertTrue("TIME" in transcription)