Skip to content

Commit

Permalink
🐛 fix Box() index #49 add testcase
Browse files Browse the repository at this point in the history
  • Loading branch information
zhzLuke96 committed Jun 16, 2024
1 parent 1788318 commit d982e33
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
11 changes: 11 additions & 0 deletions tests/api/test_tts.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,17 @@ def test_synthesize_tts(client):
f.write(response.content)


@pytest.mark.tts_api
def test_long_same_text_synthesize_tts(client):
tts_params = default_tts_params.copy()
tts_params["text"] = tts_params["text"] * 12

response = client.get("/v1/tts", params=tts_params)
print(response.content)
assert response.status_code == 200
assert response.headers["content-type"] in ["audio/wav", "audio/mpeg"]


@pytest.mark.tts_api
def test_synthesize_tts_missing_text(client):
tts_params = default_tts_params.copy()
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

parser = argparse.ArgumentParser(description="Test")
setup_model_args(parser)
args = parser.parse_args()
args, unknown = parser.parse_known_args()
process_model_args(args)
config.runtime_env_vars.off_tqdm = True
devices.reset_device()
Expand Down

0 comments on commit d982e33

Please sign in to comment.