general: migrate modules to use 3.9 features
This commit is contained in:
parent
d3f9a8e8b6
commit
8496d131e7
125 changed files with 889 additions and 739 deletions
|
@ -1,4 +1,4 @@
|
|||
from typing import Iterator
|
||||
from collections.abc import Iterator
|
||||
|
||||
import pytest
|
||||
from more_itertools import one
|
||||
|
|
|
@ -1,8 +1,10 @@
|
|||
from pathlib import Path
|
||||
import pytz
|
||||
from my.core.cfg import tmp_config
|
||||
|
||||
import pytest
|
||||
import pytz
|
||||
|
||||
from my.body.weight import from_orgmode
|
||||
from my.core.cfg import tmp_config
|
||||
|
||||
|
||||
def test_body_weight() -> None:
|
||||
|
|
|
@ -1,14 +1,11 @@
|
|||
import os
|
||||
from pathlib import Path
|
||||
|
||||
from more_itertools import bucket
|
||||
import pytest
|
||||
|
||||
|
||||
from my.core.cfg import tmp_config
|
||||
from more_itertools import bucket
|
||||
|
||||
from my.coding.commits import commits
|
||||
|
||||
from my.core.cfg import tmp_config
|
||||
|
||||
pytestmark = pytest.mark.skipif(
|
||||
os.name == 'nt',
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
To test my.location.fallback_location.all
|
||||
"""
|
||||
|
||||
from collections.abc import Iterator
|
||||
from datetime import datetime, timedelta, timezone
|
||||
from typing import Iterator
|
||||
|
||||
import pytest
|
||||
from more_itertools import ilen
|
||||
|
|
|
@ -1,16 +1,14 @@
|
|||
import pytest
|
||||
from more_itertools import consume
|
||||
|
||||
from my.core.cfg import tmp_config
|
||||
from my.core.utils.itertools import ensure_unique
|
||||
|
||||
from .common import testdata
|
||||
|
||||
|
||||
# deliberately use mixed style imports on the top level and inside the methods to test tmp_config stuff
|
||||
# todo won't really be necessary once we migrate to lazy user config
|
||||
import my.reddit.all as my_reddit_all
|
||||
import my.reddit.rexport as my_reddit_rexport
|
||||
from my.core.cfg import tmp_config
|
||||
from my.core.utils.itertools import ensure_unique
|
||||
|
||||
from .common import testdata
|
||||
|
||||
|
||||
def test_basic_1() -> None:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue