Skip to content

Commit

Permalink
tests: Skip virt tests in Github Actions
Browse files Browse the repository at this point in the history
The Github Actions runners have some weird issues with nested virtualization.

Signed-off-by: Stéphane Graber <[email protected]>
  • Loading branch information
stgraber committed Dec 16, 2024
1 parent b7441d3 commit 795dbd9
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions internal/acctest/checks.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package acctest

import (
"fmt"
"os"
"strings"
"testing"

Expand Down Expand Up @@ -69,6 +70,10 @@ func PreCheckAPIExtensions(t *testing.T, extensions ...string) {
// PreCheckVirtualization skips the test if the Incus server does not
// support virtualization.
func PreCheckVirtualization(t *testing.T) {
if os.Getenv("GITHUB_ACTIONS") == "true" {
t.Skipf("Test %q skipped. Virtualization tests can't run in Github Actions.", t.Name())
}

p := testProvider()
server, err := p.InstanceServer("", "", "")
if err != nil {
Expand Down

0 comments on commit 795dbd9

Please sign in to comment.