Skip to content

Add unit tests for voice.py and speech.py#114

Open
Santoshh7 wants to merge 1 commit intosugarlabs:mainfrom
Santoshh7:add-unit-tests
Open

Add unit tests for voice.py and speech.py#114
Santoshh7 wants to merge 1 commit intosugarlabs:mainfrom
Santoshh7:add-unit-tests

Conversation

@Santoshh7
Copy link
Copy Markdown

First unit tests for the activity. Covers:

  • _friendly_name() formatting and capitalization
  • Voice class special name handling (RP, USA, West Midlands)
  • Voice class sorting behaviour
  • KOKORO_LANG_MAP completeness (all 9 language codes present)
  • Correct lang_code detection for Hindi, Japanese, English voices

Tests use unittest.mock to stub all Sugar/GStreamer dependencies so they run on any platform without Sugar installed.

First unit tests for the activity. Covers:
- _friendly_name() formatting and capitalization
- Voice class special name handling (RP, USA, West Midlands)
- Voice class sorting behaviour
- KOKORO_LANG_MAP completeness (all 9 language codes present)
- Correct lang_code detection for Hindi, Japanese, English voices

Tests use unittest.mock to stub all Sugar/GStreamer dependencies
so they run on any platform without Sugar installed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant