Bump pytest version and add current directory to python path
Review Request #12288 — Created May 18, 2022 and submitted — Latest diff uploaded
Running unit tests using
pytest <args>
was broken because pytest was importing
test.settings
from Django Evolution instead of from Djblets. This happened
because pytest does not add the current directory to the Python Path, so
depending on the order in which Django Evolution and Djblets were installed and
registered in the Python Path, the wrongtest.settings
module could be picked
up. To fix this we update our pytest to the latest version (any version >7
works) and set pytest'spythonpath
config variable to include the current
directory.
Ran
./setup.py develop --all-pyvers
to ensure that pytest 7.1.2 was
installed and successfully ran unit tests usingpytest djblets/forms/tests