Simplify config discovery: get rid of the hacky stub and reimport proper config automatically

This commit is contained in:
Dima Gerasimov 2020-05-04 22:52:43 +01:00 committed by karlicoss
parent fd224d8c38
commit 636060db57
10 changed files with 35 additions and 25 deletions

View file

@ -9,6 +9,11 @@ def setup_notes_path(notes: Path) -> None:
config.orgmode = SimpleNamespace( # type: ignore[misc,assignment]
roots=[notes],
)
# TODO FIXME ugh. this belongs to tz provider or global config or someting
import pytz
config.weight = SimpleNamespace( # type: ignore[misc,assignment]
default_timezone = pytz.timezone('Europe/London')
)
def test_dynamic_configuration(notes: Path) -> None: