Skip to content

Commit

Permalink
Skip git pillar tests when executed inside a container
Browse files Browse the repository at this point in the history
These tests require a Git repository container, which is hard to correctly set
up when executing the tests in the container in GH Actions.

Using --network host can help, but there was still an error (the git repos were
empty) when I tried to set this up.
  • Loading branch information
agraul committed Feb 12, 2024
1 parent 1b066da commit cf5699a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/integration/pillar/test_git_pillar.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@
https://github.com/unbit/uwsgi/commit/ac1e354
"""

import os
import random
import string
import sys
Expand Down Expand Up @@ -100,9 +101,11 @@
except Exception: # pylint: disable=broad-except
HAS_PYGIT2 = False

INSIDE_CONTAINER = os.getenv("HOSTNAME", "") == "salt-test-container"
pytestmark = [
SKIP_INITIAL_PHOTONOS_FAILURES,
pytest.mark.skip_on_platforms(windows=True, darwin=True),
pytest.mark.skipif(INSIDE_CONTAINER, reason="Communication problems between containers."),
]


Expand Down

0 comments on commit cf5699a

Please sign in to comment.