diff --git a/tox.ini b/tox.ini index 0b27125..eb73a72 100644 --- a/tox.ini +++ b/tox.ini @@ -3,14 +3,12 @@ [tox] # The following configuration will run automatically. -envlist = py{37}-{default,legacy_wexpect,spawn_pipe},installed,pyinstaller +envlist = py{37}-{legacy_wexpect,spawn_pipe},installed,pyinstaller + [testenv] description = Unit tests -passenv = - WEXPECT_* - # Set environment variables to select the proper configuration for each envirnment. setenv = spawn_pipe: WEXPECT_SPAWN_CLASS=SpawnPipe @@ -33,48 +31,46 @@ commands = # https://tox.readthedocs.io/en/latest/config.html#environment-variable-substitutions coverage xml --omit=tests/*,site-packages -o {env:TOX_ENV_NAME}_coverage.xml + [testenv:installed] -# normal tests test the cloned files. This testenv tests the installation itself. -description = Unit tests installed +# normal tests test the cloned files. This testenv tests the installation itself, with the default +# spawn class. +description = Unit tests installed, and default spawn class. changedir = test_01_installed -whitelist_externals = +whitelist_externals = cp -# Appveyor will set the WEXPECT_SPAWN_CLASS to run the proper configuration for each run. -passenv = - WEXPECT_* - commands = - # copy all testcase into working dir cp -r ../tests tests - - # Run the test itself - python -m unittest + + # Run the test itself. Running all tests is not needed, because it just test the installation, + # not functions. + python -m unittest tests.test_misc + [testenv:pyinstaller] # Test if wexpect working with pyinstaller. See #12 for more details. description = Unit tests pyinstaller -whitelist_externals = +whitelist_externals = pyinstaller pyinstaller_test - + setenv = WEXPECT_SPAWN_CLASS=SpawnPipe - + commands = # install the dependencies: pip install .[test] - + # create wexpect executable for console-reader. pyinstaller wexpect.spec - + # create test executable, to thest the console-reader pyinstaller tests/pyinstaller_test.py - + # run test: dist\pyinstaller_test\pyinstaller_test.exe -