Commit Graph

238 Commits

Author SHA1 Message Date
Kubernetes Prow Robot
4364ef6206
Merge pull request #95678 from SaiHarshaK/kubectl-version-check
check if kubectl version required values are empty
2020-11-05 02:46:54 -08:00
Sai Harsha Kottapalli
06148eda25
check if kubectl version required values are empty 2020-11-05 02:51:43 +05:30
Carlos Panato
a9ff313c5b
use patch instead of replace to test the dry-run option 2020-11-03 14:27:16 +01:00
Maciej Szulik
788ef39cab
Fix --dry-run invocation in kubectl e2e 2020-10-15 12:51:58 +02:00
Ricardo Pchevuzinske Katz
ab129349ac Change kubectl clusterinfo to non offensive words
Signed-off-by: Ricardo Pchevuzinske Katz <ricardo.katz@gmail.com>
2020-10-01 08:25:52 -03:00
Kubernetes Prow Robot
660e1e4969
Merge pull request #94789 from zhouya0/cleanup_ns_flag
Clean up remaining ns flag
2020-09-17 07:08:45 -07:00
Clayton Coleman
aaa90476cb
test/e2e: Busybox image is not being templatized
All images used by e2e tests must use templates in order to allow
relocation. In addition this is hitting Dockerhub which will be
getting throttled soon.
2020-09-16 14:54:03 -04:00
Manuel Alejandro de Brito Fontes
ee2c4e514f
Refactor kubectl without stdin test 2020-09-16 09:31:59 -03:00
Kubernetes Prow Robot
3e8e0dbf4a
Merge pull request #94482 from oomichi/expect_no_error-2
Use ExpectNoError(err) for some e2e tests
2020-09-15 18:27:19 -07:00
zhouya0
438ec9be49 Clean up remaining ns flag 2020-09-15 10:43:51 +08:00
Maciej Szulik
eec4a04c2d
Use namespace flag passed to RunKubectl* methods 2020-09-11 14:51:03 +02:00
Kenichi Omichi
12c0eaef25 Use ExpectNoError(err)
We missed another pattern to check error doesn't happen on e2e tests.
This covers the pattern for consistent test implementation.
2020-09-03 23:29:07 +00:00
zhouya0
b18e265315 [Flaky test]kubectl log test never restart pod 2020-08-12 18:26:18 +08:00
Jefftree
ace97738e2 Update formatting of conformance comment 2020-07-29 20:50:44 -07:00
Ciprian Hacman
5d87704ed3 Skip arch dependent kubectl test for non AMD64 nodes 2020-07-13 20:25:14 +03:00
Aaron Crickenberger
28768166f5 decouple testfiles from framework
This drops testfiles.ReadOrDie and updated testfiles.Exists to return an
error, forcing the caller to decide whether to call framework.Fail or do
something else.

It makes for a slightly less friendly API, but also means the package is
decoupled from framework again, as per the comments at the top of the
file
2020-06-29 14:54:09 -07:00
Benjamin Elder
f2b2d44614 s/master/primary in agnhost guestbook usage 2020-06-24 12:14:33 -07:00
Benjamin Elder
279ce5d89e s/master/primary in agnhost guestbook test references & agnhost code
to do in follow-up: update the agnhost deployments and references to those when the new image is pushed
2020-06-19 12:23:16 -07:00
Benjamin Elder
d65a3b15bf update agnhost guestbook usage for s/slave/replica/ 2020-06-15 20:08:27 -07:00
Benjamin Elder
3298dfa73a up sleep time in racy test 2020-06-10 17:23:27 -07:00
Kubernetes Prow Robot
d32875543b
Merge pull request #91227 from aojea/kcliwait
kubectl run test: the pod wait (some time) until attach before printing
2020-05-20 19:41:20 -07:00
Kubernetes Prow Robot
62a4cb930b
Merge pull request #90367 from julianvmodesto/conformance-diff-dry-run
Promote diff and dry-run to conformance
2020-05-20 16:44:19 -07:00
Antonio Ojea
a0f0e58373 kubectl run test wait until pod terminates
the test "executing a command with run and attach without stdin"
is inherently flaky, there are several discussion but seems that
it requires changing the way the kubectl run and attach works.

The test fails if we are not able to attach before the container prints
"stdin closed", but hasn't exited yet.

Because the race seems difficult to solve, we can wait 5 seconds
 before printing to give time to kubectl to attach to the container.
2020-05-19 13:09:32 +02:00
Julian V. Modesto
7af0011884 Promote diff and dry-run to conformance 2020-05-13 13:04:41 -04:00
Maciej Szulik
6f1484256d
waitForPod should use different exitCondition depending on restart policy 2020-04-24 16:30:46 +02:00
Yuiko Mori
9c87deb487 Move WaitForService() into e2eservice 2020-04-17 00:11:13 +00:00
Kubernetes Prow Robot
51d41dfdb1
Merge pull request #89542 from julianvmodesto/diff-dry-run-conformance
Add kubectl diff and server-side dry-run to e2e tests
2020-04-15 19:50:45 -07:00
tanjunchen
6532b40f21 move function RemoveTaintOffNode in test/e2e/framework/util.go to subpackage node 2020-04-08 09:59:44 +08:00
Julian V. Modesto
f448c01651 Add kubectl diff + server-side dry-run to e2e 2020-04-02 20:54:53 -04:00
Jordan Liggitt
93c7b24562 github.com/googleapis/gnostic v0.4.1 2020-03-31 23:07:50 -04:00
Kubernetes Prow Robot
4e9dd8fd36
Merge pull request #89454 from gavinfish/import-aliases
Update .import-aliases for e2e test framework
2020-03-27 14:35:54 -07:00
Jie Shen
68a4b7d621
Move assertCleanup() to e2e kubectl (#89452)
* Move assertCleanup() to e2e kubectl

* Update test/e2e/kubectl/kubectl.go

Co-Authored-By: SataQiu <1527062125@qq.com>

Co-authored-by: SataQiu <1527062125@qq.com>
2020-03-25 11:20:06 -07:00
drfish
dfab6b637f Update .import-aliases for e2e test framework 2020-03-25 11:40:02 +08:00
Jordan Liggitt
a35ca04dd6 Remove kubectl column output test 2020-03-11 22:59:51 -04:00
Jordan Liggitt
b7c2faf26c client-go dynamic client: add context to callers 2020-03-06 10:56:23 -05:00
Jordan Liggitt
b19dc3a474 client-go dynamic client: update DeleteOptions callers 2020-03-06 10:21:23 -05:00
Mike Danese
c58e69ec79 automated refactor 2020-03-05 14:59:46 -08:00
Julian V. Modesto
932500c015 Remove deprecated rolling-update command 2020-02-13 23:52:53 -05:00
Kubernetes Prow Robot
f8f6229d77
Merge pull request #87950 from tanjunchen/fix-no-non-ascii-characters-/test
test/ : fix non-ascii characters
2020-02-10 17:22:15 -08:00
tanjunchen
e96b037be3 test/ : fix non-ascii characters 2020-02-09 01:40:44 +08:00
Mike Danese
3aa59f7f30 generated: run refactor 2020-02-07 18:16:47 -08:00
Kubernetes Prow Robot
60dd5dbd8b
Merge pull request #87597 from mikedanese/rctx
Refactor context handling in rest.Request
2020-01-29 22:11:03 -08:00
Mike Danese
968adfa993 cleanup req.Context() and ResponseWrapper 2020-01-29 08:50:45 -08:00
Mike Danese
d55d6175f8 refactor 2020-01-29 08:50:45 -08:00
Maciej Szulik
82f97775b7
Remove kubectl run generators 2020-01-22 16:44:00 +01:00
toyoda
0c12ae5240 Modify alias of e2e/framework/job to e2ejob 2020-01-17 10:56:05 +09:00
tanjunchen
3d34a814d6 test/e2e/kubectl test/e2e_kubeadm:Use e2eskipper package 2020-01-11 14:32:19 +08:00
danielqsj
6596a14d39 add missing alias of api errors under test 2019-12-26 17:29:38 +08:00
danielqsj
fc738cbb1d unify alias of api errors under test 2019-12-26 16:40:45 +08:00
Kubernetes Prow Robot
7fdefe5002
Merge pull request #84735 from liggitt/wardle-example-e2e
wardle example e2e
2019-12-17 12:00:28 -08:00
Jordan Liggitt
8111bb3d77 Update wardle e2e image 2019-12-16 11:06:11 -05:00
tanjunchen
f786cb07b7 test/e2e/: use framework.Equal() replace gomega.Expect(...).To(gomega.BeTrue()|BeFalse()) 2019-12-13 10:11:47 +08:00
Kubernetes Prow Robot
688149a0c6
Merge pull request #84613 from MorrisLaw/breakout-kubectl-from-utils
move KubectlCmd out of utils into its own package
2019-12-06 15:51:53 -08:00
Jordan Liggitt
bacab3d457 Deflake kubectl custom printing test 2019-12-05 15:44:25 -05:00
MorrisLaw
b85adbf1fd moved WriteFileViaContainer and ReadFileViaContainer to kubectl_utils 2019-12-04 20:31:57 +00:00
MorrisLaw
cd8da67b03 move KubectlCmd out of utils into its own package 2019-12-04 20:30:43 +00:00
Jordan Liggitt
deb75da17b fixup kubectl test 2019-11-26 13:20:52 -05:00
Jordan Liggitt
834246ca70 Skip Node printing in kubectl column test 2019-11-15 21:16:46 -05:00
Kubernetes Prow Robot
77e110fcef
Merge pull request #84046 from bclau/tests/agnhost-guestbook-replacement
Tests/agnhost guestbook replacement
2019-11-14 08:29:34 -08:00
Kenichi Omichi
74f68dfbce Move functions from e2e/framework/util.go Part-4
This is the last PR which moves functions from e2e/framework/util.go

- WaitForServiceWithSelector: Moved to e2e/cloud/gcp
- WaitForStatefulSetReplicasReady: Moved to e2e/storage
- WaitForRCToStabilize: Moved to e2e/kubectl
- CheckInvariants: Moved to e2e/common
- ContainerInitInvariant: Moved to e2e/common
- DumpEventsInNamespace: Renamed to local function
- WaitForDaemonSets: Moved to e2e/e2e.go
2019-11-12 19:25:23 +00:00
Claudiu Belu
e8d062bd4a tests: Replaces guestbook with agnhost equivalent
The redis version has been bumped to version 5.0.5, but the maximum version supported on
Windows is 3.2. This can lead to failing tests, the output and behaviour can be different
(see #80516). In order to prevent such failures, the amount of times the Redis image is
used can be reduced.

This commit uses the previously added agnhost guestbook subcommand as a replacement for the
Guestbook application created by the test "should create and stop a working application".

Adds AgnhostPrivate to test/utils/image/manifest. Some tests are trying to pull
the agnhost image from the private registry, meaning that we would need to
always build and push the agnhost image to both e2e and private registry
whenever we bump its version. Decoupling them would mean that we only need
to push the image to the e2e registry.
2019-11-12 07:23:04 -08:00
Rob Scott
1ae53a15e6
Limiting the scope of new kubectl get e2e tests to decrease flakiness
The `kubectl get output` e2e test I'd previously added ended up being
flaky in certain e2e test scenarios. It relies on getting a list of API
resources in the cluster and running `kubectl get` calls against them.
The problem ended up being that other e2e tests could create resources
that would cause this test to fail. This change limits the scope of the
tests to not cover CRDs. This should still allow the test to catch new
Kubernetes resources with improperly configured kubectl output while
limiting the flakiness of the test.
2019-11-07 11:58:30 -08:00
Rob Scott
8ae5632859
Adding e2e test to ensure kubectl get output is using custom columns when desired.
This uses etcd test data to load resources and then ensures that
kubectl get output contains a different set of columns than default.
This assumes that all future API resources will either have appropriate
kubectl get output or add an exception here.

Co-authored-by: Luis Sanchez <sanchezl@redhat.com>
2019-11-01 14:08:08 -07:00
SataQiu
24f374a395 move test specific functions from rc_util.go 2019-10-29 13:04:59 +08:00
Kubernetes Prow Robot
cae9bbd059
Merge pull request #81358 from bclau/tests/replace-redis-image
tests: Replaces Redis image with Agnhost
2019-10-16 22:24:51 -07:00
Kubernetes Prow Robot
b622b15ad4
Merge pull request #79814 from k-toyoda-pi/e2e_add_kubectl_describe_cronjob
Add e2e test for kubectl describe cronjob
2019-09-26 13:02:34 -07:00
carlory
5bbedd39c0 use log funcs of core framework in the auth, kubectl and windows pkg 2019-09-15 21:39:54 +08:00
Kubernetes Prow Robot
51e9ff8579
Merge pull request #82224 from liggitt/debug-kubectl-e2e-log
Add debug info to kubectl e2e
2019-09-11 10:41:04 -07:00
Claudiu Belu
b91aa9a5c3 tests: Replaces Redis image with Agnhost
Some tests are using the Redis image, but they do not explicitly need it.
This commit replaces the usage of the Redis image with the Agnhost image
in such test cases.
2019-09-09 00:25:18 -07:00
Kubernetes Prow Robot
1866891f71
Merge pull request #79235 from justinsb/fix_73099
kubectl attach test: wait for input before proceeding
2019-09-06 04:36:57 -07:00
toyoda
60d8bf4464 Add e2e test for kubectl describe cronjob 2019-09-05 17:08:09 +09:00
Jordan Liggitt
6b961eb08c Add debug info to kubectl e2e 2019-09-01 21:55:09 -04:00
Maciej Szulik
6939e77277
Remove kubectl log 2019-08-29 16:10:48 +02:00
Kubernetes Prow Robot
8bf4bdc7f3
Merge pull request #79910 from k-toyoda-pi/replace_KubeDescribe_e2e_kubectl
Replace KubeDescribe with ginkgo.Describe in e2e/kubectl
2019-08-22 23:27:16 -07:00
Kubernetes Prow Robot
dd0fb73a61
Merge pull request #81393 from oomichi/cleanup-ReadOrDie
Remove fail argument from ReadOrDie()
2019-08-21 10:36:31 -07:00
Joe Betz
1d429a615c Update e2e tests to use CRD v1 API 2019-08-19 18:31:14 -07:00
Kenichi Omichi
cd24b24725 Remove fail argument from ReadOrDie()
Every caller of ReadOrDie() specified ginkgo.Fail as fail argument,
and that was intentional to avoid depending on Ginkgo.
However that just spreaded the dependency on Ginkgo to caller sides.
Especially that was unnecessary e2e test framework "ingress" depended
on Ginkgo only for the above reason.
Now we are cleaning up the dependencies on e2e tests, so let's just
remove such dependencies.
2019-08-14 00:35:51 +00:00
Ted Yu
010d838264 Hide bearer token in logs 2019-08-13 09:36:15 -07:00
Kubernetes Prow Robot
da4248602d
Merge pull request #80516 from adelina-t/refactor_kubectl_test
Refactor kubectl retrieve logs test to use agnhost
2019-08-05 19:57:53 -07:00
Kubernetes Prow Robot
cce048123d
Merge pull request #80610 from aojea/ipv6kubectl
Add ipv6 support to the e2e kubectl tests
2019-08-05 13:36:02 -07:00
Adelina Tuvenie
f8a38220e3 Refactor kubectl retrieve logs test to use agnhost
Windows is having trouble running this test because the Redis
port for Windows is older than the one used by the test, as
described in the issue #80265.

Changing the "Kubectl should retrieve and filter logs" test
to use the agnhost image to generate the logs.

Fixes: https://github.com/kubernetes/kubernetes/issues/80265
2019-07-30 21:57:43 +03:00
Sean Sullivan
9f3384f02f Move pkg/kubectl/polymorphichelpers staging 2019-07-30 10:10:30 -07:00
Antonio Ojea
8988965df1
Add ipv6 support to the e2e kubectl tests 2019-07-26 00:40:46 +02:00
Kubernetes Prow Robot
0ba6ecca72
Merge pull request #77155 from draveness/feature/refactor-util-service
refactor: move service related functions in service pkg
2019-07-23 15:52:15 -07:00
Clayton Coleman
86426b9f60
Pod e2e for reading last line can flake if pod runs to completion
Pod completes so fast the current check fails:

```
Jul 18 07:09:24.858: INFO: Running '/usr/bin/kubectl --server=https://api.ci-op-ziq360tf-12fbf.origin-ci-int-aws.dev.rhcloud.com:6443 --kubeconfig=/tmp/admin.kubeconfig run run-log-test --generator=run-pod/v1 --image=docker.io/library/busybox:1.29 --restart=OnFailure --namespace=e2e-tests-kubectl-nxzxx -- sh -c sleep 10; seq 100 | while read i; do echo $i; sleep 0.01; done; echo EOF'
...
Jul 18 07:09:25.116: INFO: Waiting up to 5m0s for pod "run-log-test" in namespace "e2e-tests-kubectl-nxzxx" to be "running and ready"
Jul 18 07:09:25.135: INFO: Pod "run-log-test": Phase="Pending", Reason="", readiness=false. Elapsed: 19.221661ms
...
Jul 18 07:09:57.456: INFO: Pod "run-log-test": Phase="Pending", Reason="", readiness=false. Elapsed: 32.339426605s
Jul 18 07:09:59.477: INFO: Pod "run-log-test": Phase="Succeeded", Reason="", readiness=false. Elapsed: 34.360446811s
...
Jul 18 07:14:24.023: INFO: Pod "run-log-test": Phase="Succeeded", Reason="", readiness=false. Elapsed: 4m58.906706065s
Jul 18 07:14:26.023: INFO: Pod run-log-test failed to be running and ready.
```

The test should be reporting running and ready or succeeded.
2019-07-20 22:09:27 -04:00
draveness
c38ae01f8e feat: move service_util to separated package 2019-07-19 08:32:39 +08:00
Kubernetes Prow Robot
9ac3fadbad
Merge pull request #80126 from aojea/redis
Use docker official redis images
2019-07-15 21:51:24 -07:00
Antonio Ojea
048f7a212b
Adjust redis matching strings 2019-07-13 18:37:43 +02:00
toyoda
baddd2fd3b Replace KubeDescribe with ginkgo.Describe in e2e/kubectl 2019-07-08 18:03:40 +09:00
toyoda
5a5886035b Use ExpectEqual in e2e/kubectl 2019-07-03 13:55:19 +09:00
Jordan Liggitt
6ca80760fd Switch test manifests to apps/v1, remove beta workloads calls 2019-06-22 13:58:07 -07:00
Justin SB
0c57ad0004
kubectl attach test: wait for input before proceeding
This way we know stdin is attached and we are in a known state.
2019-06-22 15:45:58 -04:00
SataQiu
332be4b1e3 refactor: replace framework.Failf with e2elog.Failf 2019-06-19 17:52:35 +08:00
Kubernetes Prow Robot
7abf2832bf
Merge pull request #78614 from liggitt/remove-beta-e2e-use
Move test/e2e use to v1 APIs
2019-06-14 07:58:38 -07:00
Kubernetes Prow Robot
b8ba75bcd9
Merge pull request #77526 from alejandrox1/framework_util_pod_refactor
Refactored pod-related functions from framework/util.go
2019-06-13 23:06:19 -07:00
Jordan Liggitt
044e92b5cf Fix kubectl apply skew test with extra properties 2019-06-06 14:55:52 -04:00
Jordan Liggitt
8229af31d2 Move test/e2e use to v1 APIs 2019-06-03 14:46:08 -04:00
Jorge Alarcon Ochoa
4969a05327 Refactored pod-related functions from framework/util.go
This a refactoring of framework/utils.go into framework/pod.

Signed-off-by: Jorge Alarcon Ochoa <alarcj137@gmail.com>
2019-05-30 09:30:26 -04:00
Jiatong Wang
76f76450ca Move service_util endpoints related to framework/endpoints
Signed-off-by: Jiatong Wang <wangjiatong@vmware.com>
2019-05-20 11:47:38 -07:00
Kubernetes Prow Robot
583fcb91ca
Merge pull request #77976 from soltysh/validate_true
Don't rely on defaults enforce flags we rely on in tests
2019-05-17 07:00:51 -07:00