diff --git a/tests/utils/test_subtitle_processor.py b/tests/utils/test_subtitle_processor.py index 8cf05151..afa61e5d 100644 --- a/tests/utils/test_subtitle_processor.py +++ b/tests/utils/test_subtitle_processor.py @@ -14,3 +14,13 @@ def test_clean_vtt_removes_metadata_and_timestamps(): """ result = SubtitleProcessor.clean_vtt(vtt_content) assert result == "Hello Hello world" + +def test_format_as_markdown_empty_metadata(): + text = "This is a sentence. This is another! And a third?" + metadata = {} + + result = SubtitleProcessor.format_as_markdown(text, metadata) + + assert "# Unknown Title" in result + assert "**Channel:** Unknown Channel" in result + assert "This is a sentence. This is another! And a third?" in result