Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Workaround for tox w/o setup.py bug #3316

Merged
merged 1 commit into from
Nov 25, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 11 additions & 12 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ requires =
pip >= 20.2.4

[testenv]
usedevelop = True
# both options needed to workaround https://github.com/tox-dev/tox/issues/2197
usedevelop = False
skip_install = True

# do not put * in passenv as it may break builds do to reduced isolation
passenv =
CI
Expand All @@ -45,19 +48,14 @@ setenv =
PYTHONUNBUFFERED=1
_EXTRAS=-l --cov=molecule --no-cov-on-fail --cov-report xml:{envlogdir}/coverage.xml --html={envlogdir}/reports.html --self-contained-html
deps =
--editable .[docker,lint,podman,test,windows]
devel: git+https://github.com/ansible/ansible#egg=ansible-core
# pytest-molecule not used but we want to check that it does not conflict
devel: git+https://github.com/ansible-community/pytest-molecule#egg=pytest-molecule
dockerfile: ansible>=2.10
selinux
py{36,37}: importlib-metadata>=0.12
py: ansible-core
extras =
docker
lint
podman
test
windows
; commands_pre =
; find {toxinidir} -type f -not -path '{toxinidir}/.tox/*' -path '*/__pycache__/*' -name '*.py[c|o]' -delete
; sh -c 'find {homedir}/.cache -type d -path "*/molecule_*" -exec rm -rfv \{\} +;'
Expand Down Expand Up @@ -123,8 +121,8 @@ commands =
python -c \
'import pathlib; '\
'docs_dir = pathlib.Path(r"{toxinidir}") / "docs/docstree/html"; index_file = docs_dir / "index.html"; print(f"\nDocumentation available under `file://\{index_file\}`\n\nTo serve docs, use `python3 -m http.server --directory \{docs_dir\} 0`\n")'
extras =
docs
deps =
--editable .[docs]

[testenv:docs-livereload]
description = Invoke sphinx-autobuild to build and reload the HTML docs
Expand All @@ -134,15 +132,16 @@ usedevelop = {[testenv:docs]usedevelop}
commands =
python -m sphinx_autobuild docs/ "{toxworkdir}/docs/html"
deps =
--editable .[docs]
sphinx-autobuild>=0.7.1,<1.0
extras =
docs

[testenv:dockerfile]
description = Tests validity of embedded Dockerfile template used by docker driver
commands =
ansible-playbook src/molecule/data/validate-dockerfile.yml
extras =
deps =
ansible-core
paramiko
docker
selinux

Expand Down