Skip to content

Commit

Permalink
Merge pull request kubevirt#3646 from phoracek/label_masquerade_conne…
Browse files Browse the repository at this point in the history
…ctivity_tests

label tests of connectivity over masquerade
  • Loading branch information
kubevirt-bot authored Jun 28, 2020
2 parents 9878708 + e0ec464 commit 381c7c3
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions tests/expose_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
Context("Expose ClusterIP service", func() {
const servicePort = "27017"
const serviceName = "cluster-ip-vmi"
It("[test_id:1531]Should expose a Cluster IP service on a VMI and connect to it", func() {
It("[test_id:1531][label:masquerade_binding_connectivity]Should expose a Cluster IP service on a VMI and connect to it", func() {
By("Exposing the service via virtctl command")
virtctl := tests.NewRepeatableVirtctlCommand(expose.COMMAND_EXPOSE, "virtualmachineinstance", "--namespace",
tcpVM.Namespace, tcpVM.Name, "--port", servicePort, "--name", serviceName, "--target-port", strconv.Itoa(testPort))
Expand Down Expand Up @@ -143,7 +143,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
const servicePort = "27017"
const serviceName = "node-port-vmi"

It("[test_id:1534]Should expose a NodePort service on a VMI and connect to it", func() {
It("[test_id:1534[label:masquerade_binding_connectivity]Should expose a NodePort service on a VMI and connect to it", func() {
By("Exposing the service via virtctl command")
virtctl := tests.NewRepeatableVirtctlCommand(expose.COMMAND_EXPOSE, "virtualmachineinstance", "--namespace",
tcpVM.Namespace, tcpVM.Name, "--port", servicePort, "--name", serviceName, "--target-port", strconv.Itoa(testPort),
Expand Down Expand Up @@ -189,7 +189,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
const servicePort = "28017"
const serviceName = "cluster-ip-udp-vmi"

It("[test_id:1535]Should expose a ClusterIP service on a VMI and connect to it", func() {
It("[test_id:1535][label:masquerade_binding_connectivity]Should expose a ClusterIP service on a VMI and connect to it", func() {
By("Exposing the service via virtctl command")
virtctl := tests.NewRepeatableVirtctlCommand(expose.COMMAND_EXPOSE, "virtualmachineinstance", "--namespace",
udpVM.Namespace, udpVM.Name, "--port", servicePort, "--name", serviceName, "--target-port", strconv.Itoa(testPort),
Expand All @@ -216,7 +216,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
const servicePort = "29017"
const serviceName = "node-port-udp-vmi"

It("[test_id:1536]Should expose a NodePort service on a VMI and connect to it", func() {
It("[test_id:1536][label:masquerade_binding_connectivity]Should expose a NodePort service on a VMI and connect to it", func() {
By("Exposing the service via virtctl command")
virtctl := tests.NewRepeatableVirtctlCommand(expose.COMMAND_EXPOSE, "virtualmachineinstance", "--namespace",
udpVM.Namespace, udpVM.Name, "--port", servicePort, "--name", serviceName, "--target-port", strconv.Itoa(testPort),
Expand Down Expand Up @@ -295,7 +295,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
const servicePort = "27017"
const serviceName = "cluster-ip-vmirs"

It("[test_id:1537]Should create a ClusterIP service on VMRS and connect to it", func() {
It("[test_id:1537][label:masquerade_binding_connectivity]Should create a ClusterIP service on VMRS and connect to it", func() {
By("Expose a service on the VMRS using virtctl")
virtctl := tests.NewRepeatableVirtctlCommand(expose.COMMAND_EXPOSE, "vmirs", "--namespace",
vmrs.Namespace, vmrs.Name, "--port", servicePort, "--name", serviceName, "--target-port", strconv.Itoa(testPort))
Expand Down Expand Up @@ -363,7 +363,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
})

Context("Expose a VM as a ClusterIP service.", func() {
It("[test_id:1538]Connect to ClusterIP service that was set when VM was offline.", func() {
It("[test_id:1538][label:masquerade_binding_connectivity]Connect to ClusterIP service that was set when VM was offline.", func() {
// This TC also covers:
// [test_id:1795] Exposed VM (as a service) can be reconnected multiple times.
By("Getting back the cluster IP given for the service")
Expand All @@ -388,7 +388,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
waitForJobToCompleteWithStatus(&virtClient, job, k8sv1.PodSucceeded, 120)
})

It("[test_id:345]Should verify the exposed service is functional before and after VM restart.", func() {
It("[test_id:345][label:masquerade_binding_connectivity]Should verify the exposed service is functional before and after VM restart.", func() {
vmObj := vm

By("Getting back the service's allocated cluster IP.")
Expand Down Expand Up @@ -440,7 +440,7 @@ var _ = Describe("[rfe_id:253][crit:medium][vendor:[email protected]][level:comp
waitForJobToCompleteWithStatus(&virtClient, job, k8sv1.PodSucceeded, 120)
})

It("[test_id:343]Should Verify an exposed service of a VM is not functional after VM deletion.", func() {
It("[test_id:343][label:masquerade_binding_connectivity]Should Verify an exposed service of a VM is not functional after VM deletion.", func() {
By("Getting back the cluster IP given for the service")
svc, err := virtClient.CoreV1().Services(vm.Namespace).Get(serviceName, k8smetav1.GetOptions{})
Expect(err).ToNot(HaveOccurred())
Expand Down
2 changes: 1 addition & 1 deletion tests/vmi_networking_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ var _ = Describe("[rfe_id:694][crit:medium][vendor:[email protected]][level:comp
return vmi
}

table.DescribeTable("[test_id:1780]should allow regular network connection", func(ports []v1.Port, withCustomCIDR bool) {
table.DescribeTable("[test_id:1780][label:masquerade_binding_connectivity]should allow regular network connection", func(ports []v1.Port, withCustomCIDR bool) {
var ipv4NetworkCIDR string

if withCustomCIDR {
Expand Down

0 comments on commit 381c7c3

Please sign in to comment.