4 envlist = py3, pylint, flake8diff
7 allowlist_externals=/bin/cp, /bin/bash, /bin/rm
11 OSDF_CONFIG_FILE={toxinidir}/test/config/osdf_config.yaml
13 /bin/cp config/slicing_config.yaml test/config/
14 /bin/bash test/functest/scripts/start-simulators.sh
15 coverage run --module pytest --junitxml xunit-results.xml
16 coverage xml --omit=".tox/py3/*","test/*"
17 coverage report -m --omit=".tox/py3/*","test/*"
18 /bin/bash test/functest/scripts/stop-simulators.sh
19 /bin/rm test/config/slicing_config.yaml
20 # TODO: need to update the above "omit" when we package osdf as pip-installable
21 deps = -r{toxinidir}/requirements.txt
22 -r{toxinidir}/test/test-requirements.txt
23 -r{toxinidir}/requirements-osdf.txt
24 -r{toxinidir}/requirements-opteng.txt
27 source=./apps/,./osdf/,osdfapp.py,./runtime/,solverapp.py
30 allowlist_externals=bash
31 commands = bash -c "pylint --reports=y osdf apps runtime| tee pylint.out"
38 allowlist_externals=bash
41 bash -c "files=$(git diff HEAD^ HEAD --diff-filter=d --name-only | grep -E '(^apps\/|osdf\/|runtime\/)'| grep -E '*\.py$'); if [[ -z $files ]]; then exit 0; else flake8 $files; fi"
46 ignore = W503 #conflict with W504
47 per-file-ignores= apps/pci/optimizers/__init__.py:F401