- docs: SCOPE_CONTROL, CONTRIBUTING, README, .github templates - frontend: DeveloperDashboardView, Player components, MSW handlers, auth, reactQuerySync - backend: playback_analytics, playlist_service, testutils, integration README Excluded (artifacts): .auth, playwright-report, test-results, storybook_audit_detailed.json
18 lines
449 B
Go
18 lines
449 B
Go
package testutils
|
|
|
|
import (
|
|
"os/exec"
|
|
"testing"
|
|
)
|
|
|
|
// SkipIfDockerUnavailable skips the test if Docker is not available (for testcontainers).
|
|
// Also skips when testing.Short() is true.
|
|
func SkipIfDockerUnavailable(t *testing.T) {
|
|
t.Helper()
|
|
if testing.Short() {
|
|
t.Skip("Skipping database test in short mode")
|
|
}
|
|
if _, err := exec.LookPath("docker"); err != nil {
|
|
t.Skip("Docker not available, skipping test requiring testcontainers")
|
|
}
|
|
}
|