Skip to content

Commit

Permalink
Update test and docs in commonQA
Browse files Browse the repository at this point in the history
  • Loading branch information
NeonDaniel committed Nov 15, 2023
1 parent ec96839 commit 8da191a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion ovos_core/intent_services/commonqa_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,8 @@ def speak(self, utterance, message=None):
"""Speak a sentence.
Args:
utterance (str): sentence mycroft should speak
utterance (str): response to be spoken
message (Message): Message associated with request
"""
# registers the skill as being active
self.enclosure.register(self.skill_id)
Expand Down
6 changes: 4 additions & 2 deletions test/unittests/common_query/test_common_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,13 @@ def test_common_query_events(self):
{'type': 'enclosure.active_skill',
'data': {'skill_id': 'wiki.test'},
'context': qq_ctxt},
# execution of speak method
# execution of speak method. CommonQuery determines what is spoken,
# so the event comes from that skill, not the one that offered the
# selected answer
{'type': 'speak',
'data': {'utterance': 'answer 1',
'expect_response': False,
'meta': {'skill': 'wiki.test'},
'meta': {'skill': self.cc.skill_id},
'lang': 'en-us'},
'context': skill_ans_ctxt},
# skill callback event (after response is sent to Audio service)
Expand Down

0 comments on commit 8da191a

Please sign in to comment.