pytest fixtures

This submodule contains pytest fixtures which can be utilized when writing tests for your containers while using conu and pytest.

conu.fixtures.buildah_backend()

pytest fixture which mimics context manager: it provides new instance of BuildahBackend and cleans after it once it’s used; behaves the same as docker_backend fixture

Returns:instance of BuildahBackend
conu.fixtures.docker_backend()

pytest fixture which mimics context manager: it provides new instance of DockerBackend and cleans after it once it’s used; sample usage:

def test_my_container(docker_backend):
    image = docker_backend.ImageClass("fedora", tag="27")
Returns:instance of DockerBackend
conu.fixtures.podman_backend()

pytest fixture which mimics context manager: it provides new instance of PodmanBackend and cleans after it once it’s used; behaves the same as docker_backend fixture

Returns:instance of PodmanBackend