Skip to content

Commit

Permalink
Upgrade to Whisper v3
Browse files Browse the repository at this point in the history
  • Loading branch information
chidiwilliams committed Nov 8, 2023
1 parent 35369c4 commit 5efecae
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions tests/transcriber_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def test_default_output_file(self):
assert srt.endswith(".srt")

@pytest.mark.parametrize(
"expected_segments,model,check_progress",
"expected_segments,model",
[
(
[
Expand Down Expand Up @@ -248,11 +248,7 @@ def test_default_output_file(self):
],
)
def test_transcribe(
self,
qtbot: QtBot,
expected_segments: List[Segment],
model: TranscriptionModel,
check_progress,
self, qtbot: QtBot, expected_segments: List[Segment], model: TranscriptionModel
):
mock_progress = Mock()
mock_completed = Mock()
Expand Down Expand Up @@ -284,9 +280,8 @@ def test_transcribe(
transcriber.run()

# Reports progress at 0, 0 <= progress <= 100, and 100
assert mock_progress.call_count >= 3
assert mock_progress.call_count >= 2
assert mock_progress.call_args_list[0][0][0] == (0, 100)
assert mock_progress.call_args_list[-1][0][0] == (100, 100)

mock_completed.assert_called()
segments = mock_completed.call_args[0][0]
Expand Down

0 comments on commit 5efecae

Please sign in to comment.