Oscar Utbult
e4f776f230
grammar: replace all occurrences of "the the" with "the"
2022-10-14 09:03:14 +02:00
Kubernetes Prow Robot
c1602669a6
Merge pull request #112806 from dcbw/demote-service-affinity-timeout
...
test: demote service ClientIP affinity timeout tests from conformance
2022-10-11 14:12:40 -07:00
Patrick Ohly
dfdf88d4fa
e2e: adapt to moved code
...
This is the result of automatically editing source files like this:
go install golang.org/x/tools/cmd/goimports@latest
find ./test/e2e* -name "*.go" | xargs env PATH=$GOPATH/bin:$PATH ./e2e-framework-sed.sh
with e2e-framework-sed.sh containing this:
sed -i \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecCommandInContainer(/e2epod.ExecCommandInContainer(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecCommandInContainerWithFullOutput(/e2epod.ExecCommandInContainerWithFullOutput(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecShellInContainer(/e2epod.ExecShellInContainer(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecShellInPod(/e2epod.ExecShellInPod(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecShellInPodWithFullOutput(/e2epod.ExecShellInPodWithFullOutput(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.ExecWithOptions(/e2epod.ExecWithOptions(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.MatchContainerOutput(/e2eoutput.MatchContainerOutput(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.PodClient(/e2epod.NewPodClient(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.PodClientNS(/e2epod.PodClientNS(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.TestContainerOutput(/e2eoutput.TestContainerOutput(\1, /" \
-e "s/\(f\|fr\|\w\w*\.[fF]\w*\)\.TestContainerOutputRegexp(/e2eoutput.TestContainerOutputRegexp(\1, /" \
-e "s/framework.AddOrUpdateLabelOnNode\b/e2enode.AddOrUpdateLabelOnNode/" \
-e "s/framework.AllNodes\b/e2edebug.AllNodes/" \
-e "s/framework.AllNodesReady\b/e2enode.AllNodesReady/" \
-e "s/framework.ContainerResourceGatherer\b/e2edebug.ContainerResourceGatherer/" \
-e "s/framework.ContainerResourceUsage\b/e2edebug.ContainerResourceUsage/" \
-e "s/framework.CreateEmptyFileOnPod\b/e2eoutput.CreateEmptyFileOnPod/" \
-e "s/framework.DefaultPodDeletionTimeout\b/e2epod.DefaultPodDeletionTimeout/" \
-e "s/framework.DumpAllNamespaceInfo\b/e2edebug.DumpAllNamespaceInfo/" \
-e "s/framework.DumpDebugInfo\b/e2eoutput.DumpDebugInfo/" \
-e "s/framework.DumpNodeDebugInfo\b/e2edebug.DumpNodeDebugInfo/" \
-e "s/framework.EtcdUpgrade\b/e2eproviders.EtcdUpgrade/" \
-e "s/framework.EventsLister\b/e2edebug.EventsLister/" \
-e "s/framework.ExecOptions\b/e2epod.ExecOptions/" \
-e "s/framework.ExpectNodeHasLabel\b/e2enode.ExpectNodeHasLabel/" \
-e "s/framework.ExpectNodeHasTaint\b/e2enode.ExpectNodeHasTaint/" \
-e "s/framework.GCEUpgradeScript\b/e2eproviders.GCEUpgradeScript/" \
-e "s/framework.ImagePrePullList\b/e2epod.ImagePrePullList/" \
-e "s/framework.KubectlBuilder\b/e2ekubectl.KubectlBuilder/" \
-e "s/framework.LocationParamGKE\b/e2eproviders.LocationParamGKE/" \
-e "s/framework.LogSizeDataTimeseries\b/e2edebug.LogSizeDataTimeseries/" \
-e "s/framework.LogSizeGatherer\b/e2edebug.LogSizeGatherer/" \
-e "s/framework.LogsSizeData\b/e2edebug.LogsSizeData/" \
-e "s/framework.LogsSizeDataSummary\b/e2edebug.LogsSizeDataSummary/" \
-e "s/framework.LogsSizeVerifier\b/e2edebug.LogsSizeVerifier/" \
-e "s/framework.LookForStringInLog\b/e2eoutput.LookForStringInLog/" \
-e "s/framework.LookForStringInPodExec\b/e2eoutput.LookForStringInPodExec/" \
-e "s/framework.LookForStringInPodExecToContainer\b/e2eoutput.LookForStringInPodExecToContainer/" \
-e "s/framework.MasterAndDNSNodes\b/e2edebug.MasterAndDNSNodes/" \
-e "s/framework.MasterNodes\b/e2edebug.MasterNodes/" \
-e "s/framework.MasterUpgradeGKE\b/e2eproviders.MasterUpgradeGKE/" \
-e "s/framework.NewKubectlCommand\b/e2ekubectl.NewKubectlCommand/" \
-e "s/framework.NewLogsVerifier\b/e2edebug.NewLogsVerifier/" \
-e "s/framework.NewNodeKiller\b/e2enode.NewNodeKiller/" \
-e "s/framework.NewResourceUsageGatherer\b/e2edebug.NewResourceUsageGatherer/" \
-e "s/framework.NodeHasTaint\b/e2enode.NodeHasTaint/" \
-e "s/framework.NodeKiller\b/e2enode.NodeKiller/" \
-e "s/framework.NodesSet\b/e2edebug.NodesSet/" \
-e "s/framework.PodClient\b/e2epod.PodClient/" \
-e "s/framework.RemoveLabelOffNode\b/e2enode.RemoveLabelOffNode/" \
-e "s/framework.ResourceConstraint\b/e2edebug.ResourceConstraint/" \
-e "s/framework.ResourceGathererOptions\b/e2edebug.ResourceGathererOptions/" \
-e "s/framework.ResourceUsagePerContainer\b/e2edebug.ResourceUsagePerContainer/" \
-e "s/framework.ResourceUsageSummary\b/e2edebug.ResourceUsageSummary/" \
-e "s/framework.RunHostCmd\b/e2eoutput.RunHostCmd/" \
-e "s/framework.RunHostCmdOrDie\b/e2eoutput.RunHostCmdOrDie/" \
-e "s/framework.RunHostCmdWithFullOutput\b/e2eoutput.RunHostCmdWithFullOutput/" \
-e "s/framework.RunHostCmdWithRetries\b/e2eoutput.RunHostCmdWithRetries/" \
-e "s/framework.RunKubectl\b/e2ekubectl.RunKubectl/" \
-e "s/framework.RunKubectlInput\b/e2ekubectl.RunKubectlInput/" \
-e "s/framework.RunKubectlOrDie\b/e2ekubectl.RunKubectlOrDie/" \
-e "s/framework.RunKubectlOrDieInput\b/e2ekubectl.RunKubectlOrDieInput/" \
-e "s/framework.RunKubectlWithFullOutput\b/e2ekubectl.RunKubectlWithFullOutput/" \
-e "s/framework.RunKubemciCmd\b/e2ekubectl.RunKubemciCmd/" \
-e "s/framework.RunKubemciWithKubeconfig\b/e2ekubectl.RunKubemciWithKubeconfig/" \
-e "s/framework.SingleContainerSummary\b/e2edebug.SingleContainerSummary/" \
-e "s/framework.SingleLogSummary\b/e2edebug.SingleLogSummary/" \
-e "s/framework.TimestampedSize\b/e2edebug.TimestampedSize/" \
-e "s/framework.WaitForAllNodesSchedulable\b/e2enode.WaitForAllNodesSchedulable/" \
-e "s/framework.WaitForSSHTunnels\b/e2enode.WaitForSSHTunnels/" \
-e "s/framework.WorkItem\b/e2edebug.WorkItem/" \
"$@"
for i in "$@"; do
# Import all sub packages and let goimports figure out which of those
# are redundant (= already imported) or not needed.
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2edebug "k8s.io/kubernetes/test/e2e/framework/debug"' "$i"
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2ekubectl "k8s.io/kubernetes/test/e2e/framework/kubectl"' "$i"
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2enode "k8s.io/kubernetes/test/e2e/framework/node"' "$i"
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2eoutput "k8s.io/kubernetes/test/e2e/framework/pod/output"' "$i"
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2epod "k8s.io/kubernetes/test/e2e/framework/pod"' "$i"
sed -i -e '/"k8s.io.kubernetes.test.e2e.framework"/a e2eproviders "k8s.io/kubernetes/test/e2e/framework/providers"' "$i"
goimports -w "$i"
done
2022-10-06 08:19:47 +02:00
Dan Williams
1687916844
test: demote service ClientIP affinity timeout tests from conformance
...
During the September 29th, 2022 SIG-Network meeting we decided to
demote the two affinity timeout conformance tests. This was because:
(a) there is no documented correct behavior for these tests other than
"what kube-proxy does"
(b) even the kube-proxy behavior differs depending on the backend implementation
of iptables, IPVS, or [win]userspace (and winkernel doesn't at all)
(c) iptables uses only srcip matching, while userspace and IPVS use srcip+srcport
(d) IPVS and iptables have different minimum timeouts and we had
to hack up the test itself to make IPVS pass
(e) popular 3rd party network plugins also vary in their implementation
Our plan is to deprecate the current affinity options and re-add specific
options for various behaviors so it's clear exactly what plugins support
and which behavior (if any) we want to require for conformance in the future.
Signed-off-by: Dan Williams <dcbw@redhat.com >
2022-10-05 09:08:13 -05:00
Humble Chirammal
9e9fc2be88
various corrections in test/e2e package
...
Signed-off-by: Humble Chirammal <hchiramm@redhat.com >
2022-09-16 18:59:30 +05:30
Kubernetes Prow Robot
6c0bab878c
Merge pull request #111120 from iXinqi/lxinqi/destorying-svc-test
...
Add creating a destroying services test
2022-08-24 00:02:35 -07:00
Xinqi Li
9b48b7489e
add creating a destroying services test
2022-08-01 11:24:40 -07:00
Lars Ekman
e93f1161ea
Replace fallocate with dd in e2e tests
2022-07-23 17:22:49 +02:00
Kubernetes Prow Robot
bce7f34e96
Merge pull request #110967 from iXinqi/lxinqi/port-mutation-test
...
Add service port mutation test
2022-07-21 12:59:16 -07:00
Xinqi Li
d6f729995a
add service port mutation test
2022-07-11 11:44:49 -07:00
Dave Chen
fd4b5b629b
Stop using the deprecated method CurrentGinkgoTestDescription
...
Besides, the using of method might lead to a `concurrent map writes`
issue per the discussion here: https://github.com/onsi/ginkgo/issues/970
Signed-off-by: Dave Chen <dave.chen@arm.com >
2022-07-08 10:46:11 +08:00
Dave Chen
857458cfa5
update ginkgo from v1 to v2 and gomega to 1.19.0
...
- update all the import statements
- run hack/pin-dependency.sh to change pinned dependency versions
- run hack/update-vendor.sh to update go.mod files and the vendor directory
- update the method signatures for custom reporters
Signed-off-by: Dave Chen <dave.chen@arm.com >
2022-07-08 10:44:46 +08:00
Ryan Phillips
97db4ac963
add service e2e tests
2022-06-06 17:00:59 -05:00
Rob Scott
aa02b7a434
Updating e2e test to check EndpointSlices and Endpoints as well
2022-05-27 21:10:59 +00:00
Antonio Ojea
3a8edca2d8
e2e: services with evicted pods doesn't have endpoints
2022-05-27 06:43:03 +02:00
Andrew Sy Kim
01c178c9de
test/e2e/network: add e2e tests for ProxyTerminatingEndpoints
...
Signed-off-by: Andrew Sy Kim <andrewsy@google.com >
2022-03-29 11:37:43 -04:00
Sergiusz Urbaniak
373c08e0c7
test/e2e/framework: configure pod security admission level for e2e tests
2022-03-28 15:42:10 +02:00
hxie
83974e4940
Remove option 'T' from wget on Windows
...
Command 'wget' in Windows image agnhost does not support option timeout,
this test fails:
- should be able to up and down services
2022-02-07 00:38:07 -08:00
Martin André
5f809703a6
Revert "Fix comparison between FQDN and hostname"
...
This reverts commit 752a532c3d
.
2022-01-26 11:09:27 +01:00
Ahmed Aghadi
93d858c46e
Improve checks for test/e2e/network and test/e2e/network/netpol ( #106655 )
2021-12-07 22:07:56 -08:00
Stephen Heywood
675be94024
Promote DeleteCollection service e2e test to conformance
2021-11-10 10:19:46 +13:00
Stephen Heywood
38207e460c
Create e2e delete service collection test
...
The test validates the following endpoint
- deleteCoreV1CollectionNamespacedService
2021-11-03 10:17:23 +13:00
Tim Hockin
11a25bfeb6
De-share the Handler struct in core API ( #105979 )
...
* De-share the Handler struct in core API
An upcoming PR adds a handler that only applies on one of these paths.
Having fields that don't work seems bad.
This never should have been shared. Lifecycle hooks are like a "write"
while probes are more like a "read". HTTPGet and TCPSocket don't really
make sense as lifecycle hooks (but I can't take that back). When we add
gRPC, it is EXPLICITLY a health check (defined by gRPC) not an arbitrary
RPC - so a probe makes sense but a hook does not.
In the future I can also see adding lifecycle hooks that don't make
sense as probes. E.g. 'sleep' is a common lifecycle request. The only
option is `exec`, which requires having a sleep binary in your image.
* Run update scripts
2021-10-29 13:15:11 -07:00
Antonio Ojea
b55e6f2cd0
avoid hostNetwork pods conflict binding UDP ports
...
The agnhost pods using netexec will bind by default to the UDP
port 8081, use a different port for hostNetwork pods to avoid
scheduling conflicts and fail the tests.
2021-09-20 09:54:23 +02:00
Kubernetes Prow Robot
6b21e064be
Merge pull request #104917 from vinayakankugoyal/e2e
...
Skip externalips service tests if admission controller to deny externalip services is enabled.
2021-09-10 19:08:06 -07:00
Vinayak Goyal
b3c23290b4
Skip service external ips tests if admission controller to deny externalip services is enabled.
2021-09-10 12:51:31 -07:00
Martin Kennelly
752a532c3d
Fix comparison between FQDN and hostname
...
Agnhost's serve-hostname at endpoint /hostname
will return hostname. Pods host node name may
return FQDN. Comparison between the two fails.
Signed-off-by: Martin Kennelly <mkennell@redhat.com >
2021-08-20 10:24:41 +01:00
Kubernetes Prow Robot
851b4a2c9a
Merge pull request #104407 from aojea/host_network_collision
...
hostNetwork tests can't share the same port
2021-08-19 13:45:25 -07:00
Kubernetes Prow Robot
333eb833e5
Merge pull request #104401 from aojea/sctp_scale
...
SCTP tests run only on 2 nodes
2021-08-18 03:28:08 -07:00
Antonio Ojea
513b55b00d
hostNetwork tests can't share the same port
...
The pods using hostNetwork use the host network namespace, hence
they have to share it with the rest of the process and pods.
If several pods try to bind to the same port, the test will fail,
so we try to use a non common port, and run the different scenario
in the same test, so we only have to bind once and we avoid consuming
ports reducing the port collision risk.
2021-08-18 10:43:06 +02:00
Antonio Ojea
04d83edd3c
SCTP tests run only on 2 nodes
2021-08-17 00:42:20 +02:00
Martin Kennelly
eba9d33c3e
Fix insufficient privileges to bind to port
...
Container without elevated privileges to bind to
host port less than 1024 causes bind permission
denied error.
Increase port number greater than 1024 to allow
binding.
Signed-off-by: Martin Kennelly <mkennell@redhat.com >
2021-08-13 19:15:03 +01:00
Dan Winship
318b9a9578
remove superfluous [Feature:SCTP] tag in some test names
...
This tag was supposed to have gone away when SCTP went GA. (I think it
got screwed up due to a PR being mis-rebased after the SCTP GA merge.)
2021-07-19 14:49:53 -04:00
Andrew Sy Kim
04d59ff2df
test/e2e/network: add Service internalTrafficPolicy test for pod (w/ host network) -> pod (w/ host network)
...
Signed-off-by: Andrew Sy Kim <kim.andrewsy@gmail.com >
2021-07-06 09:22:07 -04:00
Andrew Sy Kim
9977ea371b
test/e2e/network: add Service internalTrafficPolicy test for pod -> pod (w/ host network)
...
Signed-off-by: Andrew Sy Kim <kim.andrewsy@gmail.com >
2021-07-06 09:22:06 -04:00
Andrew Sy Kim
025c95a778
test/e2e/network: add Service internalTrafficPolicy test pod (w/ host network) -> pod
...
Signed-off-by: Andrew Sy Kim <kim.andrewsy@gmail.com >
2021-07-06 09:22:06 -04:00
Andrew Sy Kim
f6bc5d0140
test/e2e/network: add Service internalTrafficPolicy test pod to pod
...
Signed-off-by: Andrew Sy Kim <kim.andrewsy@gmail.com >
2021-07-06 09:22:06 -04:00
Ciprian Hacman
1721be087d
nodeport tests: node addresses must match the service IP family
2021-06-26 10:00:46 +03:00
Antonio Ojea
916dbc335c
nodeport tests: node addresses must match the service IP family
2021-06-25 10:34:42 +02:00
Antonio Ojea
2dc4dba562
conformance test for Services should validate behavior
...
Current test for service with endpoints only validate the API objects,
however, doesn't validate that the implementation of Services works.
This mean that a cluster without any component implementing Services,
can pass Conformance.
2021-05-03 17:19:54 +02:00
Antonio Ojea
60c3480740
e2e don't set pod.Spec.NodeName directly
...
based on this comment in
ea07644522/test/e2e/framework/pod/node_selection.go (L96-L101)
// pod.Spec.NodeName should not be set directly because
// it will bypass the scheduler, potentially causing
// kubelet to Fail the pod immediately if it's out of
// resources. Instead, we want the pod to remain
// pending in the scheduler until the node has resources
// freed up.
2021-04-16 15:58:16 +02:00
Kubernetes Prow Robot
da341b5cfc
Merge pull request #100290 from ii/promote-service-status-test
...
Promote ServiceStatus lifecycle e2e test to Conformance +4 endpoint coverage
2021-03-16 15:57:16 -07:00
Stephen Heywood
af1f64bee8
Promote ServiceStatus lifecycle e2e test to Conformance
2021-03-16 10:07:05 +13:00
Kubernetes Prow Robot
faa3a5fbd4
Merge pull request #99916 from swetharepakula/eps-ga-e2e
...
Promote Endpoint Slice E2E Tests to Conformance
2021-03-08 20:47:45 -08:00
Kubernetes Prow Robot
5f0b88b043
Merge pull request #98791 from pacoxu/kubetest/external-ips
...
skip checking nodeport on external addrs in conformance tests
2021-03-08 19:22:59 -08:00
Swetha Repakula
3ef94fbe3e
Update e2e tests to use EndpointSlice v1 API
2021-03-08 09:44:47 -08:00
pacoxu
520ce44c55
skip test on External IP of NodePort in conformance test
2021-03-08 16:55:34 +08:00
Stephen Heywood
3e9c44f00e
Add lifecycle e2e test for service status
...
e2e test validates the following service status endpoints
- patchCoreV1NamespacedServiceStatus
- readCoreV1NamespacedServiceStatus
- replaceCoreV1NamespacedServiceStatus
Also includes untested service endpoint
- patchCoreV1NamespacedService
2021-03-02 12:05:52 +13:00
wojtekt
749922fa46
Cleanup SIGDescribe in test/e2e/network
2021-02-27 20:29:27 +01:00
Antonio Ojea
c9cbe41347
remove duplicate functions
2021-02-22 18:43:59 +01:00