Skip to content

Commit

Permalink
Remove redundant lyrics test files
Browse files Browse the repository at this point in the history
  • Loading branch information
snejus committed Sep 4, 2024
1 parent cecfa28 commit ed0d266
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2,238 deletions.
11 changes: 7 additions & 4 deletions test/plugins/test_lyrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
from http import HTTPStatus
from unittest.mock import MagicMock, patch

import confuse
import pytest

from beets import logging
Expand Down Expand Up @@ -195,7 +194,13 @@ def test_scrape_merge_paragraphs(self):
assert lyrics._scrape_merge_paragraphs(text) == "one\ntwo\nthree"

def test_missing_lyrics(self):
assert not google.is_lyrics(LYRICS_TEXTS["missing_texts"])
lyrics = """
Lyricsmania staff is working hard for you to add $TITLE lyrics as soon
as they'll be released by $ARTIST, check back soon!
In case you have the lyrics to $TITLE and want to send them to us, fill out
the following form.
"""
assert not google.is_lyrics(lyrics)


def url_to_filename(url):
Expand Down Expand Up @@ -225,8 +230,6 @@ def __call__(self, url, filename=None):


LYRICS_ROOT_DIR = os.path.join(_common.RSRC, b"lyrics")
yaml_path = os.path.join(_common.RSRC, b"lyricstext.yaml")
LYRICS_TEXTS = confuse.load_yaml(yaml_path)


class LyricsGoogleBaseTest(unittest.TestCase):
Expand Down
Loading

0 comments on commit ed0d266

Please sign in to comment.