From 166002d2750e52c27ebf8d614a4cfc536be8f5f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20Hells=C3=A9n?= Date: Sun, 14 Aug 2022 14:01:50 +0200 Subject: [PATCH] Rename test file --- ...est_discord_reminder_bot.py => test_countdown.py} | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) rename tests/{test_discord_reminder_bot.py => test_countdown.py} (89%) diff --git a/tests/test_discord_reminder_bot.py b/tests/test_countdown.py similarity index 89% rename from tests/test_discord_reminder_bot.py rename to tests/test_countdown.py index 0aca9da..71291e5 100644 --- a/tests/test_discord_reminder_bot.py +++ b/tests/test_countdown.py @@ -9,17 +9,11 @@ import pytz from apscheduler.jobstores.sqlalchemy import SQLAlchemyJobStore from apscheduler.schedulers.asyncio import AsyncIOScheduler -from discord_reminder_bot import __version__ -from discord_reminder_bot.main import send_to_discord from discord_reminder_bot.countdown import calculate +from discord_reminder_bot.main import send_to_discord -def test_version(): - """Check if version is 0.3.0.""" - assert __version__ == "0.3.0" - - -class TestClass: +class TestCountdown: """This tests everything. This sets up sqlite database in memory, changes scheduler timezone @@ -53,7 +47,7 @@ class TestClass: }, ) - def test_calc_countdown(self): + def test_countdown(self): """Check if calc_countdown returns days, hours and minutes.""" # FIXME: This will break when there is 0 seconds/hours/days left pattern = re.compile(r"\d* (day|days), \d* (hour|hours). \d* (minute|minutes)")