e2e

package module
v0.0.0-...-48b1995 Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

README

End to End Tests

End-to-End tests is written by Golang using Ginkgo. To run this tests, we need Docker and Golang.

Before running tests, we need following command in the e2e directory.

$ make setup

BGP

In this test, we prepare testing topologies by Containerlab.

To run the bgp e2e test, please execute the following command.

$ make bgp-e2e

We confirm following points in this test.

  • Establish peers with other routing softwares.
    • FRR
    • GoBGP
  • Establish iBGP and eBGP peers.
  • Receive paths from iBGP and eBGP peers.
  • Advertise paths to iBGP and eBGP peers.

Kubernetes

We need to run additional commands to setup a kubernetes cluster and external routes and install Sart related resources.

$ make kubernetes
$ make install-sart

After that, we can run the test.

make kubernetes-e2e

This is the topology for kubernetes e2e test.

kubernetes.drawio.svg

This tests confirm that following points.

  • Establish BGP peers via Kubernetes custom resources.
  • Assign external ip addresses to LoadBalancer services.
    • Specify an address pool.
    • Request a specific address.
    • Specify multiple address pool.
    • Change the address pool.
  • Communicate with an external client via LoadBalancer.
    • externalTrafficPolicy=Local
    • externalTrafficPolicy=Cluster
    • Change the externalTrafficPolicy
  • Restart
    • sartd-agent
    • sartd-bgp
    • sart-controller

CNI

To set up a CNI e2e test environment, we need following commands.

$ make kubernetes MODE=cni
$ make install-sart MODE=cni

After that, we can run the test.

$ make cni-e2e

The following figure shows the topology for CNI e2e test.

kubernetes-cni.drawio.svg

This test confirm that following points.

  • Establish BGP peers via Kubernetes custom resources.
  • Assign an IP address to pods from the auto assignable pool
  • Assign an IP address to pods from the non auto assignable pool
  • Connectivity of pods in the cluster
  • Restart
    • sartd-agent
    • sartd-bgp
    • sart-controller

Documentation

Index

Constants

View Source
const (
	BIN              string = "bin/"
	CONTAINERLAB_BIN string = BIN + "containerlab"
	TOPOLOGY_DIR     string = "topology/"
)

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Directories

Path Synopsis
topology
generator Module

Jump to

Keyboard shortcuts

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