Commit Graph

1405 Commits (bb4fcddd1b76ed628412b0cb0daabc5a05f87790)

Author SHA1 Message Date
David Ashpole 54e581930c fix node and kubelet start times 2018-12-05 15:07:52 -08:00
Jordan Liggitt d440ecdd3b Update non-test code to use DefaultMutableFeatureGate 2018-11-21 11:51:33 -05:00
Renaud Gaubert 1a3fbf1f13 Update e2e tests to include CSI 2018-11-17 01:52:57 +01:00
David Ashpole 630cb53f82 add kubelet grpc server for pod-resources service 2018-11-15 09:43:20 -08:00
Davanum Srinivas 954996e231
Move from glog to klog
- Move from the old github.com/golang/glog to k8s.io/klog
- klog as explicit InitFlags() so we add them as necessary
- we update the other repositories that we vendor that made a similar
change from glog to klog
  * github.com/kubernetes/repo-infra
  * k8s.io/gengo/
  * k8s.io/kube-openapi/
  * github.com/google/cadvisor
- Entirely remove all references to glog
- Fix some tests by explicit InitFlags in their init() methods

Change-Id: I92db545ff36fcec83afe98f550c9e630098b3135
2018-11-10 07:50:31 -05:00
Michael Taufen 1089cb629f Don't compare interface values in dynamic config controller
This previously caused a panic when moving lastKnownGood between two
non-nil values, because we were comparing the interface wrapper instead
of comparing the NodeConfigSources. The case of moving from one non-nil
lastKnownGood config to another doesn't appear to be tested by the e2e
node tests. I added a unit test and an e2e node test to help catch bugs
with this case in the future.
2018-11-09 10:45:12 -08:00
Davanum Srinivas 43f523d405
Switch to sigs.k8s.io/yaml from ghodss/yaml
Change-Id: Ic72b5131bf441d159012d67a6a3d87088d0e6d31
2018-11-07 13:17:32 -05:00
k8s-ci-robot 8b36038b41
Merge pull request #68483 from pohly/e2e-refactor-pr
e2e refactor
2018-10-19 12:32:01 -07:00
Mikhail Mazurskiy 55bc668f8d
Seed math/rand in TestMain before tests are executed 2018-10-11 22:07:45 +11:00
Mikhail Mazurskiy 3a243090a5
Simplify random seed initialization
There is no need to set the time zone as the result does not
depend on it
2018-10-11 21:01:15 +11:00
Patrick Ohly 8b17db7e0c e2e: modular framework
Not all users of the E2E framework want to run cloud-provider specific
tests. By splitting out the code it becomes possible to decide in
a E2E test suite which providers are supported.

This is achieved in two ways:
- the framework calls certain functions through a provider
  interface instead of calling specific cloud provider functions
  directly
- tests that are cloud-provider specific directly import the
  new provider packages

The ingress test utilities are only needed by a few tests. Splitting
them out into a separate package makes the framework simpler for test
suites not using those tests.

Fixes: #66649
2018-10-11 11:16:11 +02:00
mooncake 4894f5583d Remove the duplicated words in test files
Signed-off-by: mooncake <xcoder@tenxcloud.com>
2018-10-05 22:55:16 +08:00
Jordan Liggitt ad46728158 Switch e2e_node to etcd3 2018-10-04 11:41:16 -04:00
SataQiu 94a653f100 fix typo 2018-09-28 23:41:24 +08:00
Manjunath A Kumatagi 7b9833ce56 Update authenticated-image-pulling with fat manifest image 2018-09-27 17:43:15 +05:30
k8s-ci-robot db322a4944
Merge pull request #67841 from jiayingz/fix-e2e-node
Updates test/e2e_node/device_plugin.go to cope with recent device
2018-09-25 01:27:22 -07:00
Mayank Gaikwad 8f557da3c8 Port kubelet e2e_node tests to e2e 2018-09-17 11:33:30 +05:30
k8s-ci-robot 25cbd1c753
Merge pull request #67781 from dashpole/fix_priority_tests
Fix priority tests
2018-09-10 12:48:05 -07:00
Kubernetes Submit Queue c9de610897
Merge pull request #65250 from balajismaniam/node-perf-testing-framework
Automatic merge from submit-queue (batch tested with PRs 65250, 68241). If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

Initial node performance testing framework.

This PR adds a framework for node performance testing. 
Partially fixes: https://github.com/kubernetes/kubernetes/issues/65249.
Use the following command to run this test:
```sh
make test-e2e-node FOCUS="Node Performance Testing" SKIP="" PARALLELISM=1
```
It has been tested in the following environment:
- n1-standard-16
- Ubuntu 16.04
- docker 17.03.2

Note to reviewers:
This PR won't pass node e2e since the docker images in https://github.com/kubernetes/kubernetes/pull/65251 are required for this to function. The node e2e will fail when trying to pull the required images for testing.
2018-09-08 16:09:30 -07:00
David Ashpole 90f58c1157 critical pod test should not rely on feature gate set in framework; non-critical pods are always preemptable 2018-09-07 17:43:42 -07:00
David Ashpole 4a2ef941b8 fix eviction test panics 2018-09-07 13:35:13 -07:00
Adelina Tuvenie 8aa33c6201 Replaced hardcoded busybox image in e2e tests. 2018-09-06 10:55:17 +03:00
Balaji Subramaniam 7c4411eb28 Initial node performance testing framework. 2018-09-05 11:24:44 -07:00
Kubernetes Submit Queue d8365a9ca7
Merge pull request #68123 from mgdevstack/master-securitycontext-67032
Automatic merge from submit-queue (batch tested with PRs 67736, 68123, 68138). If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

Port security context NodeConformance e2e_node tests to e2e

**What this PR does / why we need it**:
Port all [NodeConformance] SecurityContext e2e_node tests to e2e/common.

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #67032 

**Special notes for your reviewer**:
- This PR is a continuing effort to close #67032.
- Removed ContainerRuntime constraint [as discussed](https://github.com/kubernetes/kubernetes/pull/67032#discussion_r214201870).
- Porting all [NodeConformance] tests to e2e/common which do not have node dependencies.
- Does it make sense to port [privileged test](https://github.com/kubernetes/kubernetes/blob/master/test/e2e_node/security_context_test.go#L558) to e2e/common and remove [NodeFeature:HostAccess] label from test name? 

**Release note**:

```release-note
NONE
```
/area conformance
@kubernetes/sig-node-pr-reviews
2018-09-04 12:51:35 -07:00
Lucas Käldström 8b6a7ee075
autogenerated go code, godeps, bazel and gofmt 2018-09-02 14:38:59 +03:00
Lucas Käldström 0707b1274f
Automated package reference rename 2018-09-02 14:15:38 +03:00
Kubernetes Submit Queue 8ba06eff79
Merge pull request #67571 from mgdevstack/master-commit-runtime
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

Transitioning container-runtime e2e_node test to e2e

**What this PR does / why we need it**:
This is a continuation of an existing PR #67258 to transition [few runtime NodeConformance tests](https://github.com/kubernetes/kubernetes/issues/67103#issuecomment-411483640) from e2e_node to e2e (e2e/common).

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #67103

**Special notes for your reviewer**:
In order to make simple clear naming of test, they are updated to 
> "_Container Runtime blackbox test when starting a container that exits should run with the expected status [NodeConformance]_" 
>"~~_Container Runtime Conformance Test container runtime conformance blackbox test when starting a container that exits it should run with the expected status [NodeConformance]_~~"

which requires updation of test names in test/test_owners.csv and test_owners.json file. Do we have any automated script to update these test_owners file or do we need to update them manually in both files?

Please feel free to comment incase we don't want to change test name.

Newly updated codebase includes following changes accomplishing all previously [mentioned](https://github.com/kubernetes/kubernetes/pull/67258#pullrequestreview-147294021) requested changes(reviews)
- [Test name](https://github.com/kubernetes/kubernetes/pull/67258/files#diff-0dc16dc0a015699e53bda03495adc49eR36) change.
- Container's [image name](https://github.com/kubernetes/kubernetes/pull/67258/files#diff-0dc16dc0a015699e53bda03495adc49eR144)
- [By()](https://github.com/kubernetes/kubernetes/pull/67258/files#diff-0dc16dc0a015699e53bda03495adc49eR109) statement
- [Removed test](https://github.com/kubernetes/kubernetes/pull/67258/files#diff-178a0a673bda44ea7a86bd94070df78cR137) from conformance golden list

This would close existing PR #67258
 
**Release note**:

```release-note
NONE
```
/area conformance
@kubernetes/sig-node-pr-reviews
2018-08-31 20:37:27 -07:00
Mayank Gaikwad c2683eafd2 Port security context NodeConformance e2e_node tests to e2e 2018-08-31 14:11:01 +05:30
Lucas Käldström 844487aea4
autogenerated 2018-08-29 20:21:17 +03:00
Lucas Käldström 994ac98586
Update api violations, golint failures and gofmt 2018-08-29 20:21:09 +03:00
Lucas Käldström 7a840cb4c8
automated: Rename all package references 2018-08-29 19:07:52 +03:00
Kubernetes Submit Queue ad26ca1e69
Merge pull request #67805 from linyouchong/pr-0824
Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Fix error link in comment

**What this PR does / why we need it**:
Fix error link in comment

**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:
NONE
**Release note**:
```release-note
NONE
```

/sig node
2018-08-26 14:07:28 -07:00
Jiaying Zhang 55f36946c8 Updates test/e2e_node/device_plugin.go to cope with recent device
manager change in commit 7b1ae66.
Also changes the test to make sure node is indeed ready after Kubelet
restart. The previous readiness check may use old API state but
didn't run into the issue due to the delay of waiting for pod restart.
2018-08-24 10:29:10 -07:00
linyouchong 075f37f853 Fix error link in comment 2018-08-24 17:07:43 +08:00
Mayank Gaikwad 74bc8a3211 transitioning container-runtime from e2e_node to e2e/common 2018-08-24 07:54:19 +05:30
David Ashpole a0c071e06e remove feature gates from eviction tests that are enabled by default 2018-08-22 10:49:13 -07:00
Kubernetes Submit Queue 949199e6ae
Merge pull request #67426 from yanxuean/check-both-err
Automatic merge from submit-queue (batch tested with PRs 67100, 67426). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

should check all error in ResourceCollector.Start()

Signed-off-by: yanxuean <yan.xuean@zte.com.cn>


**What this PR does / why we need it**:
1. We should check both errors.
test/e2e_node/resource_collector.go
```
func (r *ResourceCollector) Start() {
	// Get the cgroup container names for kubelet and runtime
	kubeletContainer, err := getContainerNameForProcess(kubeletProcessName, "")
	runtimeContainer, err := getContainerNameForProcess(framework.TestContext.ContainerRuntimeProcessName, framework.TestContext.ContainerRuntimePidFile)
	if err == nil {
		systemContainers = map[string]string{
			stats.SystemContainerKubelet: kubeletContainer,
			stats.SystemContainerRuntime: runtimeContainer,
		}
	}
```

2. redundant compare
The Timestamp.Equal is unlikely to occur, because we have met Timestamp.Before.
```
if oldStats, ok := oldStatsMap[name]; ok && oldStats.Timestamp.Before(newStats.Timestamp) {
			if oldStats.Timestamp.Equal(newStats.Timestamp) {
				continue
			}
			r.buffers[name] = append(r.buffers[name], computeContainerResourceUsage(name, oldStats, newStats))
		}
```
**Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*:
Fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
/sig-node
2018-08-16 11:57:32 -07:00
Kubernetes Submit Queue 99fab84c7a
Merge pull request #67100 from mkurylec/promotion-lifecycle-hook-to-conformance
Automatic merge from submit-queue (batch tested with PRs 67100, 67426). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

porting e2e_node lifecycle testcases into e2e folder under common

a) Shifted (and renamed) file existing in e2e_node to e2e/common.
b) Added these tests to the conformance suite:
- "should execute poststart exec hook properly"
-  "should execute prestop exec hook properly"
- "should execute poststart http hook properly"
- "should execute prestop http hook properly"

[reference issue](https://github.com/kubernetes/kubernetes/issues/67086) explaining the effort.
2018-08-16 11:57:28 -07:00
yanxuean ea9376a18b redundant equal compare
Signed-off-by: yanxuean <yan.xuean@zte.com.cn>
2018-08-15 17:09:45 +08:00
yanxuean 2d6ee874a5 should check all error
Signed-off-by: yanxuean <yan.xuean@zte.com.cn>
2018-08-15 17:00:12 +08:00
Kubernetes Submit Queue b6f0aed056
Merge pull request #66906 from tnozicka/rename-until
Automatic merge from submit-queue (batch tested with PRs 67071, 66906, 66722, 67276, 67039). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

#50102 Task 1: Move apimachinery/pkg/watch.Until into client-go/tools/watch.UntilWithoutRetry

**What this PR does / why we need it**:
This is a split off from https://github.com/kubernetes/kubernetes/pull/50102 to go in smaller pieces.

Moves `apimachinery/pkg/watch.Until` into `client-go/tools/watch.UntilWithoutRetry` and adds context so it is cancelable.

**Release note**:
```release-note
NONE
```

**Dev release note**:
```dev-release-note
`apimachinery/pkg/watch.Until` has been moved to `client-go/tools/watch.UntilWithoutRetry`.
While switching please consider using the new `client-go/tools/watch.UntilWithSync` or `client-go/tools/watch.Until`.
```

/cc @smarterclayton @kubernetes/sig-api-machinery-pr-reviews 
/milestone v1.12
/priority important-soon
/kind bug
(bug after the main PR which is this split from)
2018-08-14 22:43:19 -07:00
Kubernetes Submit Queue ad1483b58d
Merge pull request #66369 from wackxu/fixe2e
Automatic merge from submit-queue (batch tested with PRs 61212, 66369, 66446, 66895, 66969). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

fix e2e tests which set PodPriority are failing

fix https://github.com/kubernetes/kubernetes/issues/66357
```release-note
NONE
```
2018-08-14 21:18:08 -07:00
Tomas Nozicka 4d7747a5a3 Update Bazel 2018-08-10 09:55:41 +02:00
Tomas Nozicka 3d4a02abb5 Rename Until to UntilWithoutRetry and move to using context so it's
cancelable
2018-08-10 09:55:41 +02:00
Davanum Srinivas 789800d298
Remove ARCH specific image consideration from e2e tests
All e2e test images are now using multi-arch manifests so we should stop
looking up and using images that are specific to runtime.GOARCH

Change-Id: I5f3fd6e9a42b9fb88891c19e28a2dfcf7a14be82
2018-08-09 13:40:19 -04:00
Maria Alejandra Kurylec 21c0cae4e9 a) fixing dependencies. 2018-08-08 09:44:05 -03:00
Maria Alejandra Kurylec f79d5a19d4 a) porting e2e_node lifecycle testcases into e2e folder, under common.
b) placing them under conformance golden list.
2018-08-08 09:44:05 -03:00
Kubernetes Submit Queue 81c6b735fa
Merge pull request #67084 from spiffxp/rm-conformance-from-e2e_node
Automatic merge from submit-queue (batch tested with PRs 63572, 67084). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.

Remove [Conformance] from tests in test/e2e_node

Conformance tests live inside of test/e2e, none of the tests currently
tagged as `[Conformance]` in test/e2e_node actually get run when you run
the conformance tests with e2e.test (either directly or indirectly with
sonobuoy)

If these tests make sense as both `[NodeConformance]` and `[Conformance]`
tests, they should be ported to test/e2e/common

/kind cleanup
/area conformance
/sig architecture
/cc @bgrant0607 @smarterclayton @timothysc
/sig node
/cc @yujuhong

ref: https://github.com/kubernetes/kubernetes/issues/66875

```release-note
NONE
```
2018-08-07 21:06:04 -07:00
Aaron Crickenberger d724e979cd Remove [Conformance] from tests in e2e_node
None of these tests actually run as part of e2e testing, which is
the only way conformance tests are kicked off. They should not be
included as part of the conformance suite unless they live in
test/e2e/common
2018-08-07 10:43:59 -07:00
Davanum Srinivas 6cd8bd62fe
e2e test harness - use busybox from dockerhub
Use the same pattern everywhere in the e2e test
harness, use busybox (from dockerhub) instead
of using the one from k8s.gcr.io registry.

Change-Id: I57c3b867408c1f9478a8909c26744ea0368ff003
2018-08-07 11:22:16 -04:00