general: make time.tz.via_location user config lazy, move tests to my.tests package

also gets rid of the problematic reset_modules thingie
This commit is contained in:
Dima Gerasimov 2024-08-26 02:00:51 +01:00
parent 9912555d11
commit 9462357f2c
15 changed files with 269 additions and 233 deletions

9
my/tests/calendar.py Normal file
View file

@ -0,0 +1,9 @@
from my.calendar.holidays import is_holiday
from .shared_tz_config import config # autoused fixture
def test_is_holiday() -> None:
assert is_holiday('20190101')
assert not is_holiday('20180601')
assert is_holiday('20200906') # national holiday in Bulgaria