Documentation ¶
Overview ¶
Package framework is a package helping setting up end-to-end testing accross a Kubernetes cluster.
Index ¶
- func PingGameServer(msg, address string) (reply string, err error)
- type Framework
- func (f *Framework) CleanUp(ns string) error
- func (f *Framework) CreateGameServerAndWaitUntilReady(ns string, gs *v1alpha1.GameServer) (*v1alpha1.GameServer, error)
- func (f *Framework) WaitForGameServerState(gs *v1alpha1.GameServer, state v1alpha1.State, timeout time.Duration) (*v1alpha1.GameServer, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PingGameServer ¶
PingGameServer pings a gameserver and returns its reply
Types ¶
type Framework ¶
type Framework struct { KubeClient kubernetes.Interface AgonesClient versioned.Interface GameServerImage string }
Framework is a testing framework
func New ¶
New setups a testing framework using a kubeconfig path and the game server image to use for testing.
func (*Framework) CreateGameServerAndWaitUntilReady ¶
func (f *Framework) CreateGameServerAndWaitUntilReady(ns string, gs *v1alpha1.GameServer) (*v1alpha1.GameServer, error)
CreateGameServerAndWaitUntilReady Creates a GameServer and wait for its state to become ready.
func (*Framework) WaitForGameServerState ¶
func (f *Framework) WaitForGameServerState(gs *v1alpha1.GameServer, state v1alpha1.State, timeout time.Duration) (*v1alpha1.GameServer, error)
WaitForGameServerState Waits untils the gameserver reach a given state before the timeout expires
Click to show internal directories.
Click to hide internal directories.