Files
Antonin StefanuttiandGitHub 03969c9217 [CI]: Kuberay operator e2e tests (#1575)
This PR adds e2e tests for the operator, following up #1539 (comment).

This e2e testing enables to assert Kuberay resources, in a way that cannot be achieved with existing tests (envtest).

The e2e tests execution output is post-processed using gotestfmt:

The logs and events are gathered and uploaded are part of the workflow run:
2023-11-07 09:57:52 -08:00

32 lines
716 B
Go

package support
import (
"os"
)
const (
// KuberayTestOutputDir is the testing output directory, to write output files into.
KuberayTestOutputDir = "KUBERAY_TEST_OUTPUT_DIR"
// KuberayTestRayVersion is the version of Ray to use for testing.
KuberayTestRayVersion = "KUBERAY_TEST_RAY_VERSION"
// KuberayTestRayImage is the Ray image to use for testing.
KuberayTestRayImage = "KUBERAY_TEST_RAY_IMAGE"
)
func GetRayVersion() string {
return lookupEnvOrDefault(KuberayTestRayVersion, RayVersion)
}
func GetRayImage() string {
return lookupEnvOrDefault(KuberayTestRayImage, RayImage)
}
func lookupEnvOrDefault(key, value string) string {
if v, ok := os.LookupEnv(key); ok {
return v
}
return value
}