diff --git a/hack/jenkins/osx_integration_tests_docker.sh b/hack/jenkins/osx_integration_tests_docker.sh index da32f9d446..3635553cb5 100755 --- a/hack/jenkins/osx_integration_tests_docker.sh +++ b/hack/jenkins/osx_integration_tests_docker.sh @@ -34,13 +34,6 @@ EXTRA_TEST_ARGS="" EXPECTED_DEFAULT_DRIVER="docker" EXTERNAL="yes" -# fix mac os as a service on mac os -# https://github.com/docker/for-mac/issues/882#issuecomment-506372814 -#osascript -e 'quit app "Docker"' -#/Applications/Docker.app/Contents/MacOS/Docker --quit-after-install --unattended || true -#osascript -e 'quit app "Docker"' -#/Applications/Docker.app/Contents/MacOS/Docker --unattended & - begin=$(date +%s) while [ -z "$(docker info 2> /dev/null )" ]; do diff --git a/test/integration/main_test.go b/test/integration/main_test.go index 519d0be3af..c259933bef 100644 --- a/test/integration/main_test.go +++ b/test/integration/main_test.go @@ -97,11 +97,16 @@ func setMaxParallelism() { // Each "minikube start" consumes up to 2 cores, though the average usage is somewhat lower limit := int(math.Floor(float64(maxp) / 1.75)) - // Windows tests were failing from timeouts due to too much parallelism + // Windows and MacOS tests were failing from timeouts due to too much parallelism if runtime.GOOS == "windows" { limit /= 2 } + // Hardcode limit to 2 for macOS + if runtime.GOOS == "darwin" { + limit = 2 + } + fmt.Fprintf(os.Stderr, "Found %d cores, limiting parallelism with --test.parallel=%d\n", maxp, limit) if err := flag.Set("test.parallel", strconv.Itoa(limit)); err != nil { fmt.Fprintf(os.Stderr, "Unable to set test.parallel: %v\n", err)