1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-08-04 12:56:25 +00:00
trezor-firmware/python/tox.ini
2025-07-24 14:43:05 +02:00

39 lines
1.1 KiB
INI

# NOTE: for running the tests locally in `nix-shell`, it is necessary
# to spawn the `nix-shell` with `fullDeps` argument, so the command is:
# `nix-shell --arg fullDeps true`
# This will make sure all the python versions are installed.
[tox]
envlist =
py{38,39,310,311,312}-{minimal,default,full}
py{38,39,310,311,312}-click{7,80}
py{38,39,310,311,312}-click81
[testenv]
deps =
-rrequirements.txt
!minimal: pytest>=3.6
!minimal: pytest-random-order
!minimal: importlib-metadata!=0.21
full: -rrequirements-optional.txt
py312: setuptools
commands =
# Generate local files
python setup.py build
# Working in the local directory, try to compile all bytecode
python -m compileall src tests
# Smoke-test trezorctl
trezorctl --help
# Run test suite
!minimal: pytest -c setup.cfg --random-order tests
[testenv:py{38,39,310,311,312}-click{7,80,81}]
deps =
-rrequirements.txt
click7: click>=7,<8
click80: click>=8.0,<8.1
click81: click>=8.1,<8.2
commands =
# Smoke-test trezorctl
trezorctl --version