Commit Graph

61 Commits

Author SHA1 Message Date
Pedro Lopez Mareque
f7fc9deb18 remove old assertion and improve tests 2022-09-27 08:54:41 +02:00
Pedro Lopez Mareque
c8d814ddce fix tests 2022-09-27 08:36:56 +02:00
Pedro Lopez Mareque
89730b40d4 Run autopep8 and fix style 2022-09-27 07:38:23 +02:00
Pedro Lopez Mareque
1da8a689dd fechange e2e test strategy to add instead of replace 2022-09-26 22:42:24 +02:00
Pedro Lopez Mareque
2fd1b9469c feat: add missing e2e test for json and merge patch strategies 2022-09-26 22:39:38 +02:00
Patrick J McNerthney
7d0cd172bf It turns out SSL sockets can buffer data such that the select method is not aware of it. See:
https://docs.python.org/3/library/ssl.html#notes-on-non-blocking-sockets
  https://docs.python.org/3/library/ssl.html#ssl.SSLSocket.pending
2022-05-01 06:42:31 -10:00
Huan-Ting,Chen
c9e11d02b0 add e2e_test for create_from_directory 2022-01-21 16:33:57 +08:00
Yu Liao
6ae9260e9e Fixed test flakiness, added loop to wait for non-empty response line. 2022-01-04 12:14:02 -08:00
Yu Liao
26e6940d20 ApiregistrationV1beta1Api has been removed in 1.22 release, switch to
use ApiregistrationV1Api.
2022-01-04 11:27:47 -08:00
Aurélien Gasser
a24d1be63d
add comment 2021-12-13 19:43:29 -05:00
Aurélien Gasser
8da0080c7d
test: WSClient.returncode idempotence 2021-12-13 19:31:22 -05:00
Andrei Marin
740cda6998
Fix replication controller pods delete in tests 2021-10-06 22:04:26 +03:00
Andrei Marin
4cb2a51021
Run autopep8 on e2e test files 2021-10-06 22:04:25 +03:00
Matt Campbell
13814c0f7e Allow optional list of YAML objects as param to create_from_yaml util 2021-07-19 14:23:14 -04:00
Nabarun Pal
73f119aa7a
Skipping TestClient::test_portforward_raw due to flakiness
The test is flaking a lot resulting in dev work to be slowed down.
This needs to be investigated and resolved. Only then, the test
should be reenabled.

See: https://github.com/kubernetes-client/python/issues/1300

Signed-off-by: Nabarun Pal <pal.nabarun95@gmail.com>
2021-05-28 22:49:17 +05:30
Haowei Cai
90931037ac pod e2e: wait for the default service account to be created 2021-01-12 17:18:42 -08:00
Haowei Cai
3b95adc8f3 configmap-e2e: use labels 2021-01-11 12:34:14 -08:00
Patrick J. McNerthney
fd405e813d Implement back end raw port test container using python. 2020-11-22 10:26:43 -10:00
Patrick J. McNerthney
c1249c9cf2 Support both python 2.7 and 3.x. 2020-09-07 19:47:19 -10:00
Patrick J. McNerthney
8afcebdf8d Add test that checks for portforward port error return value. 2020-09-07 13:11:50 -10:00
Patrick J. McNerthney
49f3b6e0b5 Rework port forwarding unittest and example. 2020-09-07 07:54:47 -10:00
Patrick J. McNerthney
fada718edf Unittests and example for portforwarding ability added in python-base. 2020-09-01 18:32:48 -10:00
Haowei Cai
f452d0cef6 add basic watch configmap e2e test 2020-03-02 13:34:01 -08:00
micw523
02232a2e22 Change apis to api 2019-12-18 15:38:27 -06:00
micw523
fd9de42bab Fix deprecations introduced in v1.16 2019-09-24 16:30:10 -04:00
Oz Tiram
752373b1f9 Test getting the returncode of execution in a pod
This tests demonstrate how to execute a command in a pod and
what behavior is expected. As discussed in the commit
bf367ed6ddc63369f76df0a07b248a6711328605 in python-base this
behavior would be familiar to Python users, as `subprocess.Popen`
has the same property.
2019-09-19 10:03:43 +02:00
Kubernetes Prow Robot
41971cc6ea
Merge pull request #888 from micw523/update-nginx
Deprecate extensions/v1beta1 deployment
2019-07-30 15:15:53 -07:00
Xianglong Wang
dd72deaec2 Deprecate extensions/v1beta1 deployment 2019-07-23 21:28:04 -04:00
Kubernetes Prow Robot
1ad4afff35
Merge pull request #824 from tnqn/verbose
Fix AttributeError in create_from_yaml
2019-07-23 12:48:14 -07:00
Oz N Tiram
ab002f760d Remove obsolete test
The current PR no longer support creating from string
2019-07-23 05:33:40 +02:00
Oz N Tiram
34898387c3 Merge remote-tracking branch 'upstream/master' into util-improvements 2019-06-20 14:06:00 +02:00
Kubernetes Prow Robot
c86e4898fb
Merge pull request #782 from johscheuer/create-from-yaml-namespaced
Add method to dynamically set namespace in yaml files
2019-06-18 13:23:51 -07:00
Quan Tian
7ac1070077 Fix AttributeError in create_from_yaml
Some models don't have attribute 'status', like V1ConfigMap,
V1ClusterRole, and V1NetworkPolicy. AttributeError would be raised if
these resources are created via create_from_yaml with verbose enabled.

This patch checks if attribute 'status' exists before accessing it.
2019-05-03 10:41:00 -07:00
Oz Tiram
8d41478ed8 Explicitly use other deployment names for test
Using `nginx-app` deployment multiple times, is problematic because we get
conflicts or not found error.

Instead of trying to handle all cases, explicit different names
are used now. The tests now runs more reliably
2019-04-08 13:54:26 +02:00
Oz Tiram
2b83c683f8 Fix for a flaky test failing because k8s is slow
We create a deployment and do the following:

```
self.assertIsNotNone(dep)
```

Which does not fail, and then the code proceeds to deletion
and fails with a 404 execption in 80% of the time, but sometimes
it works. The deployment is there, but for some reason not available for
deletion.
Travis CI also showed inconsitent behaviour on this. Python3.5 passed
but all other version failed.
With this commit we wait for the deployment to become available for
deletion and only then continue.
2019-04-08 13:17:25 +02:00
Oz Tiram
0779fc9c66 Fix collection of execptions when applying yaml
This fixes of all tests and keeps the original API.

 It's the users responsiblility to do something the execptions
 when using `create_from_dict`, no air bag or breaks are supplied here.
2019-04-05 08:20:57 +02:00
Oz Tiram
50ef8746a9 Merge branch 'master' into util-improvements 2019-04-05 00:23:34 +02:00
Oz Tiram
cee4e49eda Rename create_from_map to create_from_dict, add tests 2019-03-26 23:54:34 +01:00
Johannes M. Scheuermann
15d36c9688 Use optional parameter for method 2019-03-26 21:45:14 +01:00
Johannes M. Scheuermann
06776ced35 Rebase code and add namespaced method 2019-03-25 16:17:12 +01:00
Xianglong Wang
9b989ddc2d Add rbac support for yaml 2019-03-20 17:54:33 -05:00
Kubernetes Prow Robot
84c057bfac
Merge pull request #673 from micw523/yaml-list
Extend YAML load functionality to *LIST and multi-resources
2019-03-19 13:22:24 -07:00
micw523
c0f71c3ba6 Add list / multi resource support 2019-03-19 00:36:32 -05:00
ramnes
3240b45c46 Use yaml.safe_load
See #718 for rationale.
2019-01-09 10:10:48 +01:00
micw523
5a92ba65aa Add kubectl create -f feature 2018-10-31 19:34:18 -05:00
Haowei Cai
a5ad719bcf Fix e2e test to reflect service storage refactoring 2018-03-12 15:21:38 -07:00
mbohlool
1d27f7e71b Fix end to end tests 2017-10-09 17:15:34 -07:00
mbohlool
27ba35aa81 Use stream module to call exec/attach calls 2017-09-22 11:42:59 -07:00
Jean Raby
c3d3ea82d2 Support for v4 stream protocol
- Set Sec-WebSocket-Protocol header from cfg param
- Add ERROR and RESIZE websocket channels
  As defined in pkg/kubelet/server/remotecommand/websocket.go
- Adjust tests to show v4 behavior wtr to status message
- Tweak read_all() to return only data from stdout and stderr.
2017-07-26 15:31:25 -04:00
mbohlool
5900a4c8c5 Fix Travis CI failure 2017-06-30 14:15:10 -07:00