Skip to content

Commit

Permalink
feat: make test image and tag configurable via ZEEBE_TEST_IMAGE and Z…
Browse files Browse the repository at this point in the history
…EEBE_TEST_IMAGE_TAG env variables
  • Loading branch information
Benjoyo committed Feb 1, 2024
1 parent 608a887 commit c3544e2
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions pytest_zeebe/fixtures.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import logging
import os

import pytest
from testcontainers.core.container import DockerContainer
Expand All @@ -10,7 +11,9 @@

logger = logging.getLogger(__name__)

ZEEBE_TEST_IMAGE = "camunda/zeebe-process-test-engine"
DEFAULT_ZEEBE_TEST_IMAGE = "camunda/zeebe-process-test-engine"
DEFAULT_ZEEBE_TEST_IMAGE_TAG = "latest"

AGENT_PORT = 26501
ENGINE_PORT = 26500

Expand All @@ -19,7 +22,9 @@

@pytest.fixture(scope="module")
def _container():
container = DockerContainer(ZEEBE_TEST_IMAGE)
image = os.environ.get("ZEEBE_TEST_IMAGE", DEFAULT_ZEEBE_TEST_IMAGE)
tag = os.environ.get("ZEEBE_TEST_IMAGE_TAG", DEFAULT_ZEEBE_TEST_IMAGE_TAG)
container = DockerContainer(f"{image}:{tag}")
container.with_exposed_ports(AGENT_PORT, ENGINE_PORT)
container.start()

Expand Down

0 comments on commit c3544e2

Please sign in to comment.