Documentation
¶
Overview ¶
Package test provides e2e tests for Jackal.
Index ¶
- func GetCLIName() string
- type JackalE2ETest
- func (e2e *JackalE2ETest) CleanFiles(files ...string)
- func (e2e *JackalE2ETest) GetJackalVersion(t *testing.T) string
- func (e2e *JackalE2ETest) GetLogFileContents(t *testing.T, stdErr string) string
- func (e2e *JackalE2ETest) GetMismatchedArch() string
- func (e2e *JackalE2ETest) Jackal(args ...string) (string, string, error)
- func (e2e *JackalE2ETest) Kubectl(args ...string) (string, string, error)
- func (e2e *JackalE2ETest) NormalizeYAMLFilenames(input string) string
- func (e2e *JackalE2ETest) SetupDockerRegistry(t *testing.T, port int)
- func (e2e *JackalE2ETest) SetupWithCluster(t *testing.T)
- func (e2e *JackalE2ETest) StripMessageFormatting(input string) string
- func (e2e *JackalE2ETest) TeardownRegistry(t *testing.T, port int)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetCLIName ¶
func GetCLIName() string
GetCLIName looks at the OS and CPU architecture to determine which Jackal binary needs to be run.
Types ¶
type JackalE2ETest ¶
type JackalE2ETest struct { JackalBinPath string Arch string ApplianceMode bool ApplianceModeKeep bool RunClusterTests bool }
JackalE2ETest Struct holding common fields most of the tests will utilize.
func (*JackalE2ETest) CleanFiles ¶
func (e2e *JackalE2ETest) CleanFiles(files ...string)
CleanFiles removes files and directories that have been created during the test.
func (*JackalE2ETest) GetJackalVersion ¶
func (e2e *JackalE2ETest) GetJackalVersion(t *testing.T) string
GetJackalVersion returns the current build/jackal version
func (*JackalE2ETest) GetLogFileContents ¶
func (e2e *JackalE2ETest) GetLogFileContents(t *testing.T, stdErr string) string
GetLogFileContents gets the log file contents from a given run's std error.
func (*JackalE2ETest) GetMismatchedArch ¶
func (e2e *JackalE2ETest) GetMismatchedArch() string
GetMismatchedArch determines what architecture our tests are running on, and returns the opposite architecture.
func (*JackalE2ETest) Jackal ¶
func (e2e *JackalE2ETest) Jackal(args ...string) (string, string, error)
Jackal executes a Jackal command.
func (*JackalE2ETest) Kubectl ¶
func (e2e *JackalE2ETest) Kubectl(args ...string) (string, string, error)
Kubectl executes `jackal tools kubectl ...`
func (*JackalE2ETest) NormalizeYAMLFilenames ¶
func (e2e *JackalE2ETest) NormalizeYAMLFilenames(input string) string
NormalizeYAMLFilenames normalizes YAML filenames / paths across Operating Systems (i.e Windows vs Linux)
func (*JackalE2ETest) SetupDockerRegistry ¶
func (e2e *JackalE2ETest) SetupDockerRegistry(t *testing.T, port int)
SetupDockerRegistry uses the host machine's docker daemon to spin up a local registry for testing purposes.
func (*JackalE2ETest) SetupWithCluster ¶
func (e2e *JackalE2ETest) SetupWithCluster(t *testing.T)
SetupWithCluster performs actions for each test that requires a K8s cluster.
func (*JackalE2ETest) StripMessageFormatting ¶
func (e2e *JackalE2ETest) StripMessageFormatting(input string) string
StripMessageFormatting strips any ANSI color codes and extra spaces from a given string
func (*JackalE2ETest) TeardownRegistry ¶
func (e2e *JackalE2ETest) TeardownRegistry(t *testing.T, port int)
TeardownRegistry removes the local registry.
Directories
¶
Path | Synopsis |
---|---|
Package external provides a test for interacting with external resources
|
Package external provides a test for interacting with external resources |
Package mocks contains all the mocks used in Jackal tests.
|
Package mocks contains all the mocks used in Jackal tests. |