e2e

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2021 License: Apache-2.0 Imports: 46 Imported by: 0

README

Running the Antrea end-to-end tests

Creating the test Kubernetes cluster

The tests must be run on an actual Kubernetes cluster. At the moment, we require the cluster to be created using Vagrant and the provided Vagrantfile, which you can do by following the instructions below.

Creating the test Kubernetes cluster with Vagrant

We use Vagrant to provision two Virtual Machines (one Kubernetes control-plane Node and one worker Node). The required software is installed on each machine with Ansible. By default the Vagrantfile uses VirtualBox but you should be able to edit the file to use your favorite Vagrant provider.

Dependencies

We require the following to be installed on your host machine:

  • vagrant (>= 2.0.0)
  • ansible (>= 2.4.0)
  • virtualbox (See supported versions here).
Ubuntu 18.04 (or later)

You can install all dependencies with sudo apt install vagrant ansible virtualbox.

Mac OS

You can install all the dependencies with brew:

  • brew cask install virtualbox
  • brew cask install vagrant
  • brew install ansible

If an action is required on your part, brew will let you know in its log messages.

Managing the cluster

Use the following Bash scripts to manage the Kubernetes Nodes with Vagrant:

  • ./infra/vagrant/provision.sh: create the required VMs and provision them
  • ./infra/vagrant/push_antrea.sh: load Antrea Docker image to each Node, along with the Antrea deployment YAML
  • ./infra/vagrant/suspend.sh: suspend all Node VMs
  • ./infra/vagrant/resume.sh: resume all Node VMs
  • ./infra/vagrant/destroy.sh: destoy all Node VMs, you will need to run provision.sh again to create a new cluster

Note that ./infra/vagrant/provision.sh can take a while to complete but it only needs to be run once.

IPv6 cluster

To test Antrea IPv6 support, an IPv6-only cluster can be created, by provisioning a private IPv6 network to connect Kubernetes Nodes, instead of a private IPv4 network. You simply need to invoke ./infra/vagrant/provision.sh with --ip-family v6. This option can be used even if the host machine does not support IPv6 itself. Note however that the Nodes do not have public IPv6 connectivity; they can still connect to the Internet using IPv4, which means that Docker images can be pulled without issue. Similarly, Pods (which only support IPv6) cannot connect to the Internet. To avoid issues when running Kubernetes conformance tests, we configure a proxy on the control-plane Node for all DNS traffic. While CoreDNS will reply to cluster local DNS queries directly, all other queries will be forwarded to the proxy over IPv6, and the proxy will then forward them to the default resolver for the Node (this time over IPv4). This means that all DNS queries from the Pods should succeed, even though the returned public IP addresses (IPv4 and / or IPv6) are not accessible.

You may need more recent versions of the dependencies (virtualbox, vagrant, ansible) than the ones listed above when creating an IPv6 cluster. The following versions were tested successfully:

  • vagrant 2.2.14
  • ansible 2.9.18
  • virtualbox 5.2
Debugging

You can SSH into any of the Node VMs using vagrant ssh [Node name] (must be run from the infra/vagrant directory. The control-plane Node is named k8s-node-control-plane and the worker Nodes are named k8s-node-worker-<N> (for a single worker Node, the name is k8s-node-worker-1. kubectl is installed on all the Nodes.

The kubeconfig file for the cluster can also be found locally on your machine at ./infra/vagrant/playbook/kube/config. If you install kubectl locally and set the KUBECONFIG environment variable to the absolute path of this kubeconfig file, you can run commands against your test cluster created with Vagrant. For example:

cd <directory containing this README file>
export KUBECONFIG=`pwd`/infra/vagrant/playbook/kube/config
kubectl cluster-info

Running the tests

Make sure that your cluster was provisioned and that the Antrea build artifacts were pushed to all the Nodes. You can then run the tests from the top-level directory with go test -v -timeout=30m github.com/vmware-tanzu/antrea/test/e2e (the -v enables verbose output).

If you are running the test for the first time and are using the scripts we provide under infra/vagrant to provision your Kubernetes cluster, you will therefore need the following steps:

  1. ./infra/vagrant/provision.sh
  2. make
  3. ./infra/vagrant/push_antrea.sh
  4. go test -v -timeout=30m github.com/vmware-tanzu/antrea/test/e2e

If you need to test an updated version of Antrea, just run ./infra/vagrant/push_antrea.sh and then run the tests again.

By default, if a test case fails, we write some useful debug information to a temporary directory on disk. This information includes the detailed description (obtained with kubectl describe) and the logs (obtained with kubectl logs) of each Antrea Pod at the time the test case exited. When running the tests in verbose mode (i.e. with -v), the test logs will tell you the location of that temporary directory. You may also choose your own directory using --logs-export-dir. For example:

mkdir antrea-test-logs
go test -count=1 -v -run=TestDeletePod github.com/vmware-tanzu/antrea/test/e2e --logs-export-dir `pwd`/antrea-test-logs

If the user provides a log directory which was used for a previous run, existing contents (subdirectories for each test case) will be overridden. By default the description and logs for Antrea Pods are only written to disk if a test fails. You can choose to dump this information unconditionally with --logs-export-on-success.

Testing the Prometheus Integration

The Prometheus integration tests can be run as part of the e2e tests when enabled explicitly.

  • To load Antrea into the cluster with Prometheus enabled, use: ./infra/vagrant/push_antrea.sh --prometheus
  • To run the Prometheus tests within the e2e suite, use: go test -v github.com/vmware-tanzu/antrea/test/e2e --prometheus

Running the e2e tests on a Kind cluster

The simplest way is to run the following command:

./ci/kind/test-e2e-kind.sh [options]

It will set up a two worker Node Kind cluster to run the e2e tests, and destroy the cluster after the tests stop (succeed or fail). kubectl needs to be present in your PATH to set up the test cluster. For more information on the usage of this script and the options, run:

./ci/kind/test-e2e-kind.sh --help

You can also run the e2e tests with an existing Kind cluster. Refer to this document for instructions on how to create a Kind cluster and use Antrea as the CNI. You need at least one control-plane Node and one worker Node. Before running the Go e2e tests, you will also need to copy the Antrea manifest to the control-plane Docker container:

./hack/generate-manifest.sh --kind | docker exec -i kind-control-plane dd of=/root/antrea.yml
go test -v github.com/vmware-tanzu/antrea/test/e2e -provider=kind

generate-manifest.sh supports generating the Antrea manifest with different Antrea configurations. Run ./hack/generate-manifest.sh --help to see the supported config options.

As part of code development, if you want to run the tests with local changes, then make the code changes on the local repo and build the image. You can load the new image into the kind cluster using the command below:

kind load docker-image projects.registry.vmware.com/antrea/antrea-ubuntu:latest --name <kind_cluster_name>

Running the performance test

To run all benchmarks, without the standard e2e tests:

go test -v -timeout=30m -run=XXX -bench=. \
    github.com/vmware-tanzu/antrea/test/e2e \
    --performance.http.concurrency=16

The above command uses -run=XXX to deselect all Test* tests and uses -bench=. to select all Benchmark* tests. Since performance tests take a while to complete, you need to extend the timeout duration -timeout from the default 10m to a longer one like 30m.

If you would like to run the performance tests in a different scale, you could run:

go test -v -timeout=30m -run=XXX -bench=BenchmarkCustomize \
    github.com/vmware-tanzu/antrea/test/e2e \
    --performance.http.requests=5000 \
    --performance.http.policy_rules=1000 \
    --performance.http.concurrency=16

All flags of performance tests includes:

  • performance.http.concurrency (int): Number of allowed concurrent http requests (default 1)
  • performance.http.requests (int): Total Number of http requests
  • performance.http.policy_rules (int): Number of CIDRs in the network policy
  • performance.realize.timeout (duration): Timeout of the realization of network policies (default 5m0s)

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsDirEmpty

func IsDirEmpty(name string) (bool, error)

IsDirEmpty checks whether a directory is empty or not.

func RunCommandOnNode added in v0.1.1

func RunCommandOnNode(nodeName string, cmd string) (code int, stdout string, stderr string, err error)

RunCommandOnNode is a convenience wrapper around the Provider interface RunCommandOnNode method.

Types

type ClusterInfo

type ClusterInfo struct {
	// contains filtered or unexported fields
}

type ClusterNode

type ClusterNode struct {
	// contains filtered or unexported fields
}

type Connectivity added in v0.8.0

type Connectivity struct {
	From         Pod
	To           Pod
	Connectivity PodConnectivityMark
}

type ConnectivityTable added in v1.0.0

type ConnectivityTable struct {
	Items []string

	Values map[string]map[string]PodConnectivityMark
	// contains filtered or unexported fields
}

func NewConnectivityTable added in v1.0.0

func NewConnectivityTable(items []string, defaultValue *PodConnectivityMark) *ConnectivityTable

func (*ConnectivityTable) Compare added in v1.0.0

func (ct *ConnectivityTable) Compare(other *ConnectivityTable) *TruthTable

func (*ConnectivityTable) Get added in v1.0.0

func (*ConnectivityTable) PrettyPrint added in v1.0.0

func (ct *ConnectivityTable) PrettyPrint(indent string) string

func (*ConnectivityTable) Set added in v1.0.0

func (ct *ConnectivityTable) Set(from string, to string, value PodConnectivityMark)

func (*ConnectivityTable) SetAllFrom added in v1.0.0

func (ct *ConnectivityTable) SetAllFrom(from string, value PodConnectivityMark)

func (*ConnectivityTable) SetAllTo added in v1.0.0

func (ct *ConnectivityTable) SetAllTo(to string, value PodConnectivityMark)

type CustomPod added in v0.13.0

type CustomPod struct {
	Pod    Pod
	Labels map[string]string
}

type KubernetesUtils added in v0.8.0

type KubernetesUtils struct {
	*TestData
	// contains filtered or unexported fields
}

func NewKubernetesUtils added in v0.8.0

func NewKubernetesUtils(data *TestData) (*KubernetesUtils, error)

func (*KubernetesUtils) Bootstrap added in v0.8.0

func (k *KubernetesUtils) Bootstrap(namespaces, pods []string) (*map[string][]string, error)

func (*KubernetesUtils) BuildService added in v1.0.0

func (k *KubernetesUtils) BuildService(svcName, svcNS string, port, targetPort int, selector map[string]string, serviceType *v1.ServiceType) *v1.Service

BuildService is a convenience function for building a corev1.Service spec.

func (*KubernetesUtils) CleanACNPs added in v0.12.0

func (k *KubernetesUtils) CleanACNPs() error

CleanACNPs is a convenience function for deleting all Antrea ClusterNetworkPolicies in the cluster.

func (*KubernetesUtils) CleanANPs added in v0.10.0

func (k *KubernetesUtils) CleanANPs(namespaces []string) error

CleanANPs is a convenience function for deleting all Antrea NetworkPolicies in provided namespaces.

func (*KubernetesUtils) CleanCGs added in v0.13.0

func (k *KubernetesUtils) CleanCGs() error

CleanCGs is a convenience function for deleting all ClusterGroups in the cluster.

func (*KubernetesUtils) CleanLegacyACNPs added in v1.0.0

func (k *KubernetesUtils) CleanLegacyACNPs() error

CleanLegacyACNPs is a convenience function for deleting all Antrea ClusterNetworkPolicies in the cluster.

func (*KubernetesUtils) CleanLegacyANPs added in v1.0.0

func (k *KubernetesUtils) CleanLegacyANPs(namespaces []string) error

CleanLegacyANPs is a convenience function for deleting all Antrea NetworkPolicies in provided namespaces.

func (*KubernetesUtils) CleanLegacyCGs added in v1.0.0

func (k *KubernetesUtils) CleanLegacyCGs() error

CleanCGs is a convenience function for deleting all ClusterGroups in the cluster.

func (*KubernetesUtils) CleanNetworkPolicies added in v0.8.0

func (k *KubernetesUtils) CleanNetworkPolicies(namespaces []string) error

CleanNetworkPolicies is a convenience function for deleting NetworkPolicies in the provided namespaces.

func (*KubernetesUtils) CleanServices added in v1.0.0

func (k *KubernetesUtils) CleanServices(namespaces []string) error

CleanServices is a convenience function for deleting Services in the cluster.

func (*KubernetesUtils) Cleanup added in v0.8.0

func (k *KubernetesUtils) Cleanup(namespaces []string) error

func (*KubernetesUtils) CreateCG added in v0.13.0

func (k *KubernetesUtils) CreateCG(name string, pSelector, nSelector *metav1.LabelSelector, ipBlock *crdv1alpha1.IPBlock) (*crdv1alpha2.ClusterGroup, error)

CreateCG is a convenience function for creating an Antrea ClusterGroup by name and selector.

func (*KubernetesUtils) CreateLegacyCG added in v1.0.0

func (k *KubernetesUtils) CreateLegacyCG(name string, pSelector, nSelector *metav1.LabelSelector, ipBlock *crdv1alpha1.IPBlock) (*legacycorev1a2.ClusterGroup, error)

CreateLegacyCG is a convenience function for creating a legacy Antrea ClusterGroup by name and selector.

func (*KubernetesUtils) CreateNewLegacyTier added in v1.0.0

func (k *KubernetesUtils) CreateNewLegacyTier(name string, tierPriority int32) (*legacysecv1alpha1.Tier, error)

CreateLegacyTier is a convenience function for creating a legacy Antrea Policy Tier by name and priority.

func (*KubernetesUtils) CreateNewTier added in v0.10.0

func (k *KubernetesUtils) CreateNewTier(name string, tierPriority int32) (*crdv1alpha1.Tier, error)

CreateTier is a convenience function for creating an Antrea Policy Tier by name and priority.

func (*KubernetesUtils) CreateOrUpdateACNP added in v0.12.0

CreateOrUpdateACNP is a convenience function for updating/creating AntreaClusterNetworkPolicies.

func (*KubernetesUtils) CreateOrUpdateANP added in v0.10.0

CreateOrUpdateANP is a convenience function for updating/creating Antrea NetworkPolicies.

func (*KubernetesUtils) CreateOrUpdateCG added in v0.13.0

CreateOrUpdateCG is a convenience function for idempotent setup of ClusterGroups

func (*KubernetesUtils) CreateOrUpdateDeployment added in v0.8.0

func (k *KubernetesUtils) CreateOrUpdateDeployment(ns, deploymentName string, replicas int32, labels map[string]string) (*appsv1.Deployment, error)

CreateOrUpdateDeployment is a convenience function for idempotent setup of deployments

func (*KubernetesUtils) CreateOrUpdateLegacyACNP added in v1.0.0

CreateOrUpdateLegacyACNP is a convenience function for updating/creating AntreaClusterNetworkPolicies.

func (*KubernetesUtils) CreateOrUpdateLegacyANP added in v1.0.0

CreateOrUpdateANP is a convenience function for updating/creating Antrea NetworkPolicies.

func (*KubernetesUtils) CreateOrUpdateLegacyCG added in v1.0.0

func (k *KubernetesUtils) CreateOrUpdateLegacyCG(cg *legacycorev1a2.ClusterGroup) (*legacycorev1a2.ClusterGroup, error)

CreateOrUpdateLegacyCG is a convenience function for idempotent setup of legacy ClusterGroups

func (*KubernetesUtils) CreateOrUpdateNamespace added in v0.8.0

func (k *KubernetesUtils) CreateOrUpdateNamespace(n string, labels map[string]string) (*v1.Namespace, error)

CreateOrUpdateNamespace is a convenience function for idempotent setup of Namespaces

func (*KubernetesUtils) CreateOrUpdateNetworkPolicy added in v0.8.0

func (k *KubernetesUtils) CreateOrUpdateNetworkPolicy(netpol *v1net.NetworkPolicy) (*v1net.NetworkPolicy, error)

CreateOrUpdateNetworkPolicy is a convenience function for updating/creating netpols. Updating is important since some tests update a network policy to confirm that mutation works with a CNI.

func (*KubernetesUtils) CreateOrUpdateService added in v1.0.0

func (k *KubernetesUtils) CreateOrUpdateService(svc *v1.Service) (*v1.Service, error)

CreateOrUpdateService is a convenience function for updating/creating Services.

func (*KubernetesUtils) DeleteACNP added in v1.0.0

func (k *KubernetesUtils) DeleteACNP(name string) error

DeleteACNP is a convenience function for deleting ACNP by name.

func (*KubernetesUtils) DeleteANP added in v1.0.0

func (k *KubernetesUtils) DeleteANP(ns, name string) error

DeleteANP is a convenience function for deleting ANP by name and Namespace.

func (*KubernetesUtils) DeleteCG added in v1.0.0

func (k *KubernetesUtils) DeleteCG(name string) error

DeleteCG is a convenience function for deleting ClusterGroup by name.

func (*KubernetesUtils) DeleteLegacyACNP added in v1.0.0

func (k *KubernetesUtils) DeleteLegacyACNP(name string) error

DeleteLegacyACNP is a convenience function for deleting ACNP by name.

func (*KubernetesUtils) DeleteLegacyANP added in v1.0.0

func (k *KubernetesUtils) DeleteLegacyANP(ns, name string) error

DeleteLegacyANP is a convenience function for deleting ANP by name and Namespace.

func (*KubernetesUtils) DeleteLegacyCG added in v1.0.0

func (k *KubernetesUtils) DeleteLegacyCG(name string) error

DeleteLegacyCG is a convenience function for deleting legacy ClusterGroup by name.

func (*KubernetesUtils) DeleteLegacyTier added in v1.0.0

func (k *KubernetesUtils) DeleteLegacyTier(name string) error

DeleteLegacyTier is a convenience function for deleting a legacy Antrea Policy Tier with specific name.

func (*KubernetesUtils) DeleteNetworkPolicy added in v1.0.0

func (k *KubernetesUtils) DeleteNetworkPolicy(ns, name string) error

DeleteNetworkPolicy is a convenience function for deleting NetworkPolicy by name and Namespace.

func (*KubernetesUtils) DeleteService added in v1.0.0

func (k *KubernetesUtils) DeleteService(ns, name string) error

DeleteService is a convenience function for deleting a Service by Namespace and name.

func (*KubernetesUtils) DeleteTier added in v0.10.0

func (k *KubernetesUtils) DeleteTier(name string) error

DeleteTier is a convenience function for deleting an Antrea Policy Tier with specific name.

func (*KubernetesUtils) GetACNP added in v1.0.0

GetACNP is a convenience function for getting AntreaClusterNetworkPolicies.

func (*KubernetesUtils) GetANP added in v1.0.0

func (k *KubernetesUtils) GetANP(namespace, name string) (*crdv1alpha1.NetworkPolicy, error)

GetANP is a convenience function for getting AntreaNetworkPolicies.

func (*KubernetesUtils) GetCG added in v1.0.0

GetCG is a convenience function for getting ClusterGroups

func (*KubernetesUtils) GetNetworkPolicy added in v1.0.0

func (k *KubernetesUtils) GetNetworkPolicy(namespace, name string) (*v1net.NetworkPolicy, error)

GetNetworkPolicy is a convenience function for getting k8s NetworkPolicies.

func (*KubernetesUtils) GetPodByLabel added in v1.0.0

func (k *KubernetesUtils) GetPodByLabel(ns string, name string) (*v1.Pod, error)

GetPodByLabel returns a Pod with the matching Namespace and "pod" label.

func (*KubernetesUtils) GetPodsByLabel added in v1.0.0

func (k *KubernetesUtils) GetPodsByLabel(ns string, key string, val string) ([]v1.Pod, error)

GetPodsByLabel returns an array of all Pods in the given Namespace having a k/v label pair.

func (*KubernetesUtils) GetService added in v1.0.0

func (k *KubernetesUtils) GetService(namespace, name string) (*v1.Service, error)

GetService is a convenience function for getting Service

func (*KubernetesUtils) GetTier added in v1.0.0

func (k *KubernetesUtils) GetTier(name string) (*crdv1alpha1.Tier, error)

GetTier is a convenience function for getting Tier.

func (*KubernetesUtils) LegacyCleanup added in v1.0.0

func (k *KubernetesUtils) LegacyCleanup(namespaces []string) error

func (*KubernetesUtils) Probe added in v0.8.0

func (k *KubernetesUtils) Probe(ns1, pod1, ns2, pod2 string, port int32, protocol v1.Protocol) (PodConnectivityMark, error)

Probe execs into a Pod and checks its connectivity to another Pod. Of course it assumes that the target Pod is serving on the input port, and also that agnhost is installed.

func (*KubernetesUtils) UpdateLegacyTier added in v1.0.0

func (k *KubernetesUtils) UpdateLegacyTier(tier *legacysecv1alpha1.Tier) (*legacysecv1alpha1.Tier, error)

UpdateLegacyTier is a convenience function for updating a legacy Antrea Policy Tier.

func (*KubernetesUtils) UpdateTier added in v0.12.0

func (k *KubernetesUtils) UpdateTier(tier *crdv1alpha1.Tier) (*crdv1alpha1.Tier, error)

UpdateTier is a convenience function for updating an Antrea Policy Tier.

func (*KubernetesUtils) Validate added in v0.8.0

func (k *KubernetesUtils) Validate(allPods []Pod, reachability *Reachability, port int32, protocol v1.Protocol)

type Pod added in v0.8.0

type Pod string

func NewPod added in v0.8.0

func NewPod(namespace string, podName string) Pod

func (Pod) Namespace added in v0.8.0

func (pod Pod) Namespace() string

func (Pod) PodName added in v0.8.0

func (pod Pod) PodName() string

func (Pod) String added in v0.8.0

func (pod Pod) String() string

type PodCondition

type PodCondition func(*corev1.Pod) (bool, error)

type PodConnectivityMark added in v1.0.0

type PodConnectivityMark string
const (
	Connected PodConnectivityMark = "Con"
	Unknown   PodConnectivityMark = "Unk"
	Error     PodConnectivityMark = "Err"
	Dropped   PodConnectivityMark = "Drp"
	Rejected  PodConnectivityMark = "Rej"
)

type PodIPs added in v0.11.0

type PodIPs struct {
	// contains filtered or unexported fields
}

func (PodIPs) String added in v0.11.0

func (p PodIPs) String() string

type Reachability added in v0.8.0

type Reachability struct {
	Expected *ConnectivityTable
	Observed *ConnectivityTable
	Pods     []Pod
}

func NewReachability added in v0.8.0

func NewReachability(pods []Pod, defaultExpectation PodConnectivityMark) *Reachability

func (*Reachability) Expect added in v0.8.0

func (r *Reachability) Expect(pod1 Pod, pod2 Pod, connectivity PodConnectivityMark)

func (*Reachability) ExpectAllEgress added in v0.8.0

func (r *Reachability) ExpectAllEgress(pod Pod, connectivity PodConnectivityMark)

ExpectAllEgress defines that any traffic going out of the pod will be allowed/dropped/rejected

func (*Reachability) ExpectAllIngress added in v0.8.0

func (r *Reachability) ExpectAllIngress(pod Pod, connectivity PodConnectivityMark)

ExpectAllIngress defines that any traffic going into the pod will be allowed/dropped/rejected

func (*Reachability) ExpectConn added in v0.8.0

func (r *Reachability) ExpectConn(spec *Connectivity)

ExpectConn is an experimental way to describe connectivity with named fields

func (*Reachability) ExpectSelf added in v0.8.0

func (r *Reachability) ExpectSelf(allPods []Pod, connectivity PodConnectivityMark)

func (*Reachability) Observe added in v0.8.0

func (r *Reachability) Observe(pod1 Pod, pod2 Pod, connectivity PodConnectivityMark)

func (*Reachability) PrintSummary added in v0.8.0

func (r *Reachability) PrintSummary(printExpected bool, printObserved bool, printComparison bool)

func (*Reachability) Summary added in v0.8.0

func (r *Reachability) Summary() (trueObs int, falseObs int, comparison *TruthTable)

type TestData

type TestData struct {
	// contains filtered or unexported fields
}

TestData stores the state required for each test case.

func (*TestData) GetAgentFeatures added in v0.11.0

func (data *TestData) GetAgentFeatures(antreaNamespace string) (featuregate.FeatureGate, error)

func (*TestData) GetAntreaConfigMap added in v0.8.0

func (data *TestData) GetAntreaConfigMap(antreaNamespace string) (*corev1.ConfigMap, error)

func (*TestData) GetControllerFeatures added in v0.11.0

func (data *TestData) GetControllerFeatures(antreaNamespace string) (featuregate.FeatureGate, error)

func (*TestData) GetEncapMode added in v0.4.0

func (data *TestData) GetEncapMode() (config.TrafficEncapModeType, error)

func (*TestData) GetFlowAggregatorConfigMap added in v0.12.0

func (data *TestData) GetFlowAggregatorConfigMap() (*corev1.ConfigMap, error)

func (*TestData) GetGatewayInterfaceName added in v0.8.0

func (data *TestData) GetGatewayInterfaceName(antreaNamespace string) (string, error)

type TestOptions

type TestOptions struct {
	// contains filtered or unexported fields
}

type TruthTable added in v0.8.0

type TruthTable struct {
	Items []string

	Values map[string]map[string]bool
	// contains filtered or unexported fields
}

func (*TruthTable) IsComplete added in v0.8.0

func (tt *TruthTable) IsComplete() bool

IsComplete returns true if there's a value set for every single pair of items, otherwise it returns false.

func (*TruthTable) PrettyPrint added in v0.8.0

func (tt *TruthTable) PrettyPrint(indent string) string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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