rapid-crayon-8232
03/17/2022, 9:21 AMpytest
as a dependency in your requirements.txt
and you import pytest
in your test files or conftest.py
so it is discovered by dependency inference, what pytest distribution is used for the tests ? the global defined in pants.toml
or the one in the user defined lock file ?
I know It's confusing adding pytest
as a dependency, but the main use case is for IDE support, ie: when running ./pants export //:poetry
, I'd like to have black
, isort
, pytest
, ... exported toohappy-kitchen-89482
03/17/2022, 4:18 PMhappy-kitchen-89482
03/17/2022, 4:19 PMhappy-kitchen-89482
03/17/2022, 4:19 PMhappy-kitchen-89482
03/17/2022, 4:19 PMrapid-crayon-8232
03/17/2022, 4:20 PMpython_test
use pytest as a tool
in a python_source
use pytest as a dep ?hundreds-father-404
03/17/2022, 4:21 PMIt will use the version in requirements.txt I believeIt will install Pytest twice (bleh), then I can't quite remember how Pex handles merging the two PEXes when there's the same dep. I want to say it goes with the first one encountered..
happy-kitchen-89482
03/17/2022, 4:30 PMhappy-kitchen-89482
03/17/2022, 4:32 PMrapid-crayon-8232
03/17/2022, 4:42 PM