e2e

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2020 License: Apache-2.0 Imports: 33 Imported by: 0

README

End to end tests

Adding end to end tests

Knative Serving e2e tests test the end to end functionality of the Knative Serving API to verify the behavior of this specific implementation.

These tests use the test library.

Requirements

The e2e tests are used to test whether the flow of Knative Serving is performing as designed from start to finish.

The e2e tests MUST:

  1. Provide frequent output describing what actions they are undertaking, especially before performing long running operations. Please see the Log section for detailed instructions.
  2. Follow Golang best practices.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ScaleToWithin

func ScaleToWithin(t *testing.T, scale int, duration time.Duration, latencies Latencies)

func Setup

func Setup(t *testing.T) *test.Clients

Setup creates the client objects needed in the e2e tests.

func SetupAlternativeNamespace

func SetupAlternativeNamespace(t *testing.T) *test.Clients

SetupAlternativeNamespace creates the client objects needed in e2e tests under the alternative namespace.

func SetupServingNamespaceforSecurityTesting

func SetupServingNamespaceforSecurityTesting(t *testing.T) *test.Clients

SetupServingNamespaceforSecurityTesting creates the client objects needed in e2e tests under the security testing namespace.

func SetupWithNamespace

func SetupWithNamespace(t *testing.T, namespace string) *test.Clients

SetupWithNamespace creates the client objects needed in the e2e tests under the specified namespace.

func WaitForScaleToZero

func WaitForScaleToZero(t *testing.T, deploymentName string, clients *test.Clients) error

WaitForScaleToZero will wait for the specified deployment to scale to 0 replicas. Will wait up to 6 times the configured ScaleToZeroGracePeriod before failing.

Types

type Latencies

type Latencies interface {
	// Add takes the name of this measurement and the time at which it began.
	// This should be called at the moment of completion, so that duration may
	// be computed with `time.Since(start)`.  We use this signature to that this
	// function is suitable for use in a `defer`.
	Add(name string, start time.Time)
}

Latencies is an interface for providing mechanisms for recording timings for the parts of the scale test.

Directories

Path Synopsis
autotls

Jump to

Keyboard shortcuts

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