Skip to content

Commit

Permalink
ci: Switch python tests to use public release image (#1649)
Browse files Browse the repository at this point in the history
  • Loading branch information
svix-jplatte authored Jan 20, 2025
2 parents a0d0aad + 3833469 commit e2143fb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/python-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Build svix server image
run: docker compose build
- name: Pull svix server image (and dependencies)
run: docker compose pull
working-directory: ./server

- uses: actions/setup-python@v5
Expand Down
7 changes: 7 additions & 0 deletions python/tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,20 @@ def docker_compose_command():
# fallback on v1 otherwise
return "docker-compose"

# `pytest-docker` reads this to override the location of the docker-compose.yml file
@pytest.fixture(scope="session")
def docker_compose_file():
return [
os.path.join(os.path.dirname(__file__), "../../server/docker-compose.yml"),
os.path.join(os.path.dirname(__file__), "docker-compose.override.yml"),
]

# `pytest-docker` will use this fixture to override the setup command
@pytest.fixture(scope="session")
def docker_setup():
# Don't include the default --build option in the setup
return ["up -d"]

@pytest.fixture(scope="session")
def docker_compose(docker_services):
return docker_services._docker_compose
Expand Down

0 comments on commit e2143fb

Please sign in to comment.