Skip to content

Commit

Permalink
Update tox.ini
Browse files Browse the repository at this point in the history
  • Loading branch information
hluk committed Oct 2, 2023
1 parent 34c3b00 commit 2551263
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ Note, that in order for some of the tests to work properly, tox is configured to

Should you, for some reason avoid docker, you could run the following command (with virtualenv active)::

$ NO_CAN_HAS_POSTGRES=sadly pytest
$ tox -e py311-nodocker

To use tox-docker with podman without requiring root, you can use
`tox-podman.sh` script that wraps `tox`::
Expand Down
14 changes: 9 additions & 5 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,24 @@ deps =
commands =
black --line-length=99 resultsdb testing

[testenv:py311-nodocker]
extras =
test
commands = python -m pytest {posargs}
setenv =
NO_CAN_HAS_POSTGRES = 1

[testenv:py311]
docker = resultsdb-postgres
extras =
test
commands = python -m pytest {posargs}
setenv =
PYTHONPATH = {toxinidir}
POSTGRES_5432_TCP = 15432
# needs hawkey, koji
sitepackages = False
# tests read HOME
passenv =
HOME
DOCKER_HOST
NO_CAN_HAS_POSTGRES
POSTGRES_5432_TCP

[docker:resultsdb-postgres]
image = docker.io/library/postgres:12.6
Expand Down

0 comments on commit 2551263

Please sign in to comment.