kubernetesk8s.io/kubernetes/test/utils/apiserver Index | Files

package apiserver

import "k8s.io/kubernetes/test/utils/apiserver"

Index

Types

type TestAPIServer

type TestAPIServer struct {
	// ClientSet is already initialized to access the apiserver as admin.
	ClientSet clientset.Interface

	// KubeConfigFile is the absolute path for a kube.config file that
	// grants admin access to the apiserver.
	KubeConfigFile string
}

TestAPIServer provides access to a running apiserver instance.

func StartAPITestServer

func StartAPITestServer(t *testing.T) TestAPIServer

StartAPIServer runs etcd and apiserver in the background in the same process. All resources get released automatically when the test completes. If startup fails, the test gets aborted.

Source Files

testapiserver.go

Version
v1.33.0 (latest)
Published
Apr 23, 2025
Platform
linux/amd64
Imports
12 packages
Last checked
3 hours ago

Tools for package owners.