mirror of
https://github.com/clearml/wexpect-venv
synced 2025-01-31 02:46:59 +00:00
29 lines
925 B
INI
29 lines
925 B
INI
# tox.ini
|
|
# Run tests of wexpect in multiple configuration.
|
|
|
|
[tox]
|
|
# The following configuration will run automatically.
|
|
envlist = py{37}-{default,legacy_wexpect,spawn_pipe}
|
|
|
|
[testenv]
|
|
description = Unit tests
|
|
|
|
# Set environment variables to select the proper configuration for each envirnment.
|
|
setenv =
|
|
spawn_pipe: WEXPECT_SPAWN_CLASS=SpawnPipe
|
|
legacy_wexpect: WEXPECT_SPAWN_CLASS=legacy_wexpect
|
|
|
|
commands =
|
|
# install the dependencies:
|
|
pip install .[test]
|
|
|
|
# Run the test itself
|
|
coverage run -m unittest
|
|
|
|
# Dump coverage summary to console
|
|
coverage report --omit=tests/*,site-packages/*
|
|
|
|
# Convert coverage report to standard xml formula the filename includes the tox environment name
|
|
# https://tox.readthedocs.io/en/latest/config.html#environment-variable-substitutions
|
|
coverage xml --omit=tests/*,site-packages -o {env:TOX_ENV_NAME}_coverage.xml
|