testutil

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 12, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanUpTempDir

func CleanUpTempDir(t *testing.T)

CleanUpTempDir removes temporary files and directories created during tests

func InstallCrioRegistriesConf

func InstallCrioRegistriesConf() error

InstallCrioRegistriesConf installs the custom registries.conf with registry mirror configuration This enables CRI-O to use a local registry mirror for caching Kubernetes images This is typically called during integration test setup when cache proxy is available

func PrepareSubCmdForTest

func PrepareSubCmdForTest(sub *cobra.Command) *cobra.Command

PrepareSubCmdForTest creates a root command with the given subcommand added. Use this from tests in other packages to avoid duplicating the helper.

func Reset

func Reset(t *testing.T)

Reset performs a complete cleanup of the Kubernetes environment

func Sudo

func Sudo(cmd *exec.Cmd) *exec.Cmd

Sudo prepends Sudo to the command if not running as root

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL