diff --git a/Makefile b/Makefile index 6c849986e4..a7c0584fad 100644 --- a/Makefile +++ b/Makefile @@ -30,7 +30,12 @@ vendor: @echo "✓ Filling vendor folder with library code ..." @go mod vendor +INTEGRATION = gotestsum --format github-actions --rerun-fails --jsonfile output.json --packages "./integration/..." -- -parallel 4 -timeout=2h + integration: - gotestsum --format github-actions --rerun-fails --jsonfile output.json --packages "./integration/..." -- -parallel 4 -timeout=2h + $(INTEGRATION) + +integration-short: + $(INTEGRATION) -short -.PHONY: lint lintcheck test testonly coverage build snapshot vendor integration +.PHONY: lint lintcheck test testonly coverage build snapshot vendor integration integration-short diff --git a/integration/bundle/clusters_test.go b/integration/bundle/clusters_test.go index f9e5c9b648..c153b87330 100644 --- a/integration/bundle/clusters_test.go +++ b/integration/bundle/clusters_test.go @@ -44,6 +44,11 @@ func TestDeployBundleWithCluster(t *testing.T) { require.NoError(t, err) require.NotNil(t, cluster) + if testing.Short() { + t.Log("Skip the job run in short mode") + return + } + out, err := runResource(t, ctx, root, "foo") require.NoError(t, err) require.Contains(t, out, "Hello World!") diff --git a/integration/bundle/python_wheel_test.go b/integration/bundle/python_wheel_test.go index 5cca1cb53f..f7fb1ff3f6 100644 --- a/integration/bundle/python_wheel_test.go +++ b/integration/bundle/python_wheel_test.go @@ -29,6 +29,11 @@ func runPythonWheelTest(t *testing.T, templateName, sparkVersion string, pythonW destroyBundle(t, ctx, bundleRoot) }) + if testing.Short() { + t.Log("Skip the job run in short mode") + return + } + out, err := runResource(t, ctx, bundleRoot, "some_other_job") require.NoError(t, err) require.Contains(t, out, "Hello from my func") diff --git a/integration/bundle/spark_jar_test.go b/integration/bundle/spark_jar_test.go index 65893052e0..cbdf5a00c3 100644 --- a/integration/bundle/spark_jar_test.go +++ b/integration/bundle/spark_jar_test.go @@ -30,6 +30,11 @@ func runSparkJarTestCommon(t *testing.T, ctx context.Context, sparkVersion, arti destroyBundle(t, ctx, bundleRoot) }) + if testing.Short() { + t.Log("Skip the job run in short mode") + return + } + out, err := runResource(t, ctx, bundleRoot, "jar_job") require.NoError(t, err) require.Contains(t, out, "Hello from Jar!")