style(tests): apply isort 5

grdddj/ruff_linter
matejcik 9 months ago committed by matejcik
parent b008367f38
commit b151a3db6b

@ -31,9 +31,10 @@ from . import recovery
from .common import go_next
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink, LayoutContent
from ..device_handler import BackgroundDeviceHandler
TX_CACHE_MAINNET = TxCache("Bitcoin")
TX_CACHE_TESTNET = TxCache("Testnet")

@ -30,9 +30,10 @@ from .common import (
)
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink
from ..device_handler import BackgroundDeviceHandler
pytestmark = [pytest.mark.skip_t1, pytest.mark.skip_t2]

@ -25,9 +25,10 @@ from ..common import get_test_address
from .common import CommonPass, PassphraseCategory, get_char_category
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink
from ..device_handler import BackgroundDeviceHandler
pytestmark = [pytest.mark.skip_t1, pytest.mark.skip_tr]

@ -26,9 +26,10 @@ from .. import buttons
from .common import go_back, go_next, navigate_to_action_and_press
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink
from ..device_handler import BackgroundDeviceHandler
pytestmark = pytest.mark.skip_t1

@ -25,9 +25,10 @@ from ..common import MNEMONIC12, MNEMONIC_SLIP39_BASIC_20_3of6
from . import recovery
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink
from ..device_handler import BackgroundDeviceHandler
pytestmark = [pytest.mark.skip_t1]

@ -23,9 +23,10 @@ from trezorlib import device
from trezorlib.exceptions import Cancelled
if TYPE_CHECKING:
from ..device_handler import BackgroundDeviceHandler
from trezorlib.debuglink import DebugLink
from ..device_handler import BackgroundDeviceHandler
# TR-only
pytestmark = [pytest.mark.skip_t1, pytest.mark.skip_t2]

@ -27,10 +27,12 @@ from trezorlib import btc, messages, tools
from trezorlib.messages import ButtonRequestType
if TYPE_CHECKING:
from trezorlib.debuglink import DebugLink, TrezorClientDebugLink as Client
from trezorlib.messages import ButtonRequest
from _pytest.mark.structures import MarkDecorator
from trezorlib.debuglink import DebugLink
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.messages import ButtonRequest
BRGeneratorType = Generator[None, messages.ButtonRequest, None]

@ -25,7 +25,8 @@ import xdist
from trezorlib import debuglink, log
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.device import apply_settings, wipe as wipe_device
from trezorlib.device import apply_settings
from trezorlib.device import wipe as wipe_device
from trezorlib.transport import enumerate_devices, get_transport
from . import ui_tests
@ -33,11 +34,12 @@ from .device_handler import BackgroundDeviceHandler
from .emulators import EmulatorWrapper
if TYPE_CHECKING:
from trezorlib._internal.emulator import Emulator
from _pytest.config import Config
from _pytest.config.argparsing import Parser
from _pytest.terminal import TerminalReporter
from trezorlib._internal.emulator import Emulator
HERE = Path(__file__).resolve().parent

@ -5,9 +5,10 @@ from trezorlib.client import PASSPHRASE_ON_DEVICE
from trezorlib.transport import udp
if TYPE_CHECKING:
from trezorlib.messages import Features
from trezorlib.debuglink import DebugLink, TrezorClientDebugLink as Client
from trezorlib._internal.emulator import Emulator
from trezorlib.debuglink import DebugLink
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.messages import Features
udp.SOCKET_TIMEOUT = 0.1

@ -19,7 +19,8 @@ from typing import Any
import pytest
from trezorlib import btc, messages
from trezorlib.debuglink import TrezorClientDebugLink as Client, message_filters
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.debuglink import message_filters
from trezorlib.tools import parse_path
from ...input_flows import InputFlowSignMessagePagination

@ -17,7 +17,8 @@
import pytest
from trezorlib import ethereum, exceptions, messages
from trezorlib.debuglink import TrezorClientDebugLink as Client, message_filters
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.debuglink import message_filters
from trezorlib.exceptions import TrezorFailure
from trezorlib.tools import parse_path, unharden

@ -18,7 +18,8 @@ import math
import pytest
from trezorlib import messages as m, misc
from trezorlib import messages as m
from trezorlib import misc
from trezorlib.debuglink import TrezorClientDebugLink as Client
ENTROPY_LENGTHS_POW2 = [2**l for l in range(10)]

@ -15,12 +15,9 @@ import time
from typing import Callable, Generator
from trezorlib import messages
from trezorlib.debuglink import (
DebugLink,
LayoutContent,
TrezorClientDebugLink as Client,
multipage_content,
)
from trezorlib.debuglink import DebugLink, LayoutContent
from trezorlib.debuglink import TrezorClientDebugLink as Client
from trezorlib.debuglink import multipage_content
from . import buttons
from .common import (

Loading…
Cancel
Save