avast / pytest-docker

Docker-based integration tests
MIT License
423 stars 71 forks source link

`port_for` should allow proto=udp #31

Closed vicyap closed 2 years ago

vicyap commented 5 years ago

I think it would be useful if https://github.com/AndreLouisCaron/pytest-docker/blob/master/src/pytest_docker/__init__.py#L57 had a proto='tcp' kwarg which allows your to specify the protocol.

For example.

$ docker-compose port
Print the public port for a port binding.

Usage: port [options] SERVICE PRIVATE_PORT

Options:
    --protocol=proto  tcp or udp [default: tcp]
...