From 106fe0609a0c421dd74fd391baaf67f64d0e8be4 Mon Sep 17 00:00:00 2001 From: oskvr37 Date: Thu, 23 Jan 2025 23:40:11 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20add=20more=20`FormatTrack`=20tests?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/test_utils.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/test_utils.py b/tests/test_utils.py index 24e5aeb..4fbe5f5 100644 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -111,7 +111,8 @@ class TestFormatTrack(unittest.TestCase): ("{date:%m-%d-%y}", "11-15-16"), ("{date:%Y}", "2016"), ("{year}", "2016"), - ("{playlist_number}", ""), + ("{playlist_number}", "0"), + ("{playlist_number:02d}", "00"), ("{bpm}", "69"), ("{quality}", "high"), ("{artist}/{album}/{title}", "Skepta/Konnichiwa/Shutdown"), @@ -124,7 +125,7 @@ class TestFormatTrack(unittest.TestCase): self.assertEqual(result, expected_result) def test_invalid_characters(self): - test_cases = ["\\", ":", '"', "?", "<", ">", "|", "{number}:{title}"] + test_cases = ["\\", ":", '"', "?", "<", ">", "|", "{number}:{title}", "{date}"] for template in test_cases: with self.subTest(template=template):