Skip to content

Commit 595ff64

Browse files
authored
On macOS v15.x, nsss has 177 voices (#422)
* pre-commit autoupdate 2025-08-25 * 177 voices on macOS v15
1 parent 4ba15e8 commit 595ff64

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
repos:
88
- repo: https://github.com/pre-commit/pre-commit-hooks
9-
rev: v5.0.0
9+
rev: v6.0.0
1010
hooks:
1111
- id: check-added-large-files
1212
- id: check-ast
@@ -49,7 +49,7 @@ repos:
4949
- tomli
5050

5151
- repo: https://github.com/astral-sh/ruff-pre-commit
52-
rev: v0.12.1
52+
rev: v0.12.10
5353
hooks: # Format before linting
5454
- id: ruff-check
5555
- id: ruff-format

tests/test_engines.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,9 +115,9 @@ def test_apple_nsss_voices(driver_name) -> None:
115115
)
116116
voices = engine.getProperty("voices")
117117
# On macOS v13.x or v14.x, nsss has 143 voices.
118-
# On macOS v15.x, nsss has 176 voices
118+
# On macOS v15.x, nsss has 177 voices
119119
print(f"On macOS v{macos_version}, {engine} has {len(voices) = } voices.")
120-
assert len(voices) in {176, 143}, "Expected 176 or 143 voices on macOS and iOS"
120+
assert len(voices) in {177, 143}, "Expected 177 or 143 voices on macOS and iOS"
121121
# print("\n".join(voice.id for voice in voices))
122122
en_us_voices = [voice for voice in voices if voice.id.startswith("com.apple.eloquence.en-US.")]
123123
assert len(en_us_voices) == 8, "Expected 8 com.apple.eloquence.en-US voices on macOS and iOS"

tests/test_pyttsx3.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,9 @@ def test_apple_avspeech_voices(engine):
5959
), f"Expected default voice {voice} to be com.apple.voice.compact.en-US.Samantha"
6060
voices = engine.getProperty("voices")
6161
# On macOS v14.x, nsss has 143 voices.
62-
# On macOS v15.x, nsss has 176 voices
62+
# On macOS v15.x, nsss has 177 voices
6363
print(f"On macOS v{macos_version}, {engine} has {len(voices) = } voices.")
64-
assert len(voices) in (176, 143), "Expected 176 or 143 voices on macOS and iOS"
64+
assert len(voices) in {177, 143}, "Expected 177 or 143 voices on macOS and iOS"
6565
# print("\n".join(voice.id for voice in voices))
6666
en_us_voices = [voice for voice in voices if voice.id.startswith("com.apple.eloquence.en-US.")]
6767
assert len(en_us_voices) == 8, "Expected 8 com.apple.eloquence.en-US voices on macOS and iOS"
@@ -96,9 +96,9 @@ def test_apple_nsss_voices(engine):
9696
), "Expected default voice to be com.apple.voice.compact.en-US.Samantha on macOS and iOS"
9797
voices = engine.getProperty("voices")
9898
# On macOS v14.x, nsss has 143 voices.
99-
# On macOS v15.x, nsss has 176 voices
99+
# On macOS v15.x, nsss has 177 voices
100100
print(f"On macOS v{macos_version}, {engine} has {len(voices) = } voices.")
101-
assert len(voices) in (176, 143), "Expected 176 or 143 voices on macOS and iOS"
101+
assert len(voices) in {177, 143}, "Expected 177 or 143 voices on macOS and iOS"
102102
# print("\n".join(voice.id for voice in voices))
103103
en_us_voices = [voice for voice in voices if voice.id.startswith("com.apple.eloquence.en-US.")]
104104
assert len(en_us_voices) == 8, "Expected 8 com.apple.eloquence.en-US voices on macOS and iOS"
@@ -201,7 +201,7 @@ def test_changing_volume(engine) -> None:
201201
@pytest.mark.skipif(sys.platform == "win32", reason="TODO: Fix this test to pass on Windows")
202202
def test_changing_voices(engine) -> None:
203203
voices = engine.getProperty("voices")
204-
for voice in voices: # TODO: This could be lots of voices! (e.g. 176 on macOS v15.x)
204+
for voice in voices: # TODO: This could be lots of voices! (e.g. 177 on macOS v15.x)
205205
engine.setProperty("voice", voice.id)
206206
engine.say(f"{voice.id = }. {quick_brown_fox}")
207207
engine.runAndWait()

0 commit comments

Comments
 (0)