How to set the environment variable in tox? April 9, 2024 by Tarik setenv must be in [testenv]: [tox] envlist = py35 [testenv] deps=pytest commands=py.test setenv = XYZ = 123