Skip to content

Commit

Permalink
👷 Add matrix test for testing to run with podman
Browse files Browse the repository at this point in the history
Fixes #905

♻️ Skip env tests for podman for now
  • Loading branch information
elgohr committed Dec 27, 2023
1 parent 7bbb53a commit 937bd66
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,21 @@ jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
runtime:
- '/var/run/docker.sock'
- '/run/user/$UID/podman/podman.sock'
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.21'
- name: Test
run: go test -race -timeout 0 -coverprofile=coverage.txt -covermode=atomic ./...
run: |
export DOCKER_HOST="unix://${{ matrix.runtime }}"
echo "Using ${DOCKER_HOST}"
go test -race -timeout 0 -coverprofile=coverage.txt -covermode=atomic ./...
- name: Coverage
uses: codecov/codecov-action@v3
with:
Expand Down
3 changes: 3 additions & 0 deletions localstack_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -380,6 +380,9 @@ func TestInstanceEndpointWithoutStarted(t *testing.T) {
}

func TestWithClientFromEnv(t *testing.T) {
if strings.Contains(os.Getenv("DOCKER_HOST"), "podman.sock") {
t.Skip()
}
for _, s := range []struct {
name string
given func(t *testing.T)
Expand Down

0 comments on commit 937bd66

Please sign in to comment.