Merge pull request #69021 from mgdevstack/master-kubelet-conformance

Promote kubelet NodeConformance tests to Conformance
This commit is contained in:
k8s-ci-robot 2018-10-04 18:19:25 -07:00 committed by GitHub
commit 766d860f86
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 31 additions and 6 deletions

View File

@ -92,6 +92,11 @@ test/e2e/common/init_container.go: "should invoke init containers on a RestartNe
test/e2e/common/init_container.go: "should invoke init containers on a RestartAlways pod"
test/e2e/common/init_container.go: "should not start app containers if init containers fail on a RestartAlways pod"
test/e2e/common/init_container.go: "should not start app containers and fail the pod if init containers fail on a RestartNever pod"
test/e2e/common/kubelet.go: "should print the output to logs"
test/e2e/common/kubelet.go: "should have an terminated reason"
test/e2e/common/kubelet.go: "should be possible to delete"
test/e2e/common/kubelet.go: "should write entries to /etc/hosts"
test/e2e/common/kubelet.go: "should not write to root filesystem"
test/e2e/common/kubelet_etc_hosts.go: "should test kubelet managed /etc/hosts file"
test/e2e/common/lifecycle_hook.go: "should execute poststart exec hook properly"
test/e2e/common/lifecycle_hook.go: "should execute prestop exec hook properly"

View File

@ -41,11 +41,11 @@ var _ = framework.KubeDescribe("Kubelet", func() {
podName := "busybox-scheduling-" + string(uuid.NewUUID())
/*
Release : v1.9
Release : v1.13
Testname: Kubelet, log output, default
Description: By default the stdout and stderr from the process being executed in a pod MUST be sent to the pod's logs.
*/
It("should print the output to logs [NodeConformance]", func() {
framework.ConformanceIt("should print the output to logs [NodeConformance]", func() {
podClient.CreateSync(&v1.Pod{
ObjectMeta: metav1.ObjectMeta{
Name: podName,
@ -98,7 +98,12 @@ var _ = framework.KubeDescribe("Kubelet", func() {
})
})
It("should have an terminated reason [NodeConformance]", func() {
/*
Release : v1.13
Testname: Kubelet, failed pod, terminated reason
Description: Create a Pod with terminated state. Pod MUST have only one container. Container MUST be in terminated state and MUST have an terminated reason.
*/
framework.ConformanceIt("should have an terminated reason [NodeConformance]", func() {
Eventually(func() error {
podData, err := podClient.Get(podName, metav1.GetOptions{})
if err != nil {
@ -118,7 +123,12 @@ var _ = framework.KubeDescribe("Kubelet", func() {
}, time.Minute, time.Second*4).Should(BeNil())
})
It("should be possible to delete [NodeConformance]", func() {
/*
Release : v1.13
Testname: Kubelet, failed pod, delete
Description: Create a Pod with terminated state. This terminated pod MUST be able to be deleted.
*/
framework.ConformanceIt("should be possible to delete [NodeConformance]", func() {
err := podClient.Delete(podName, &metav1.DeleteOptions{})
Expect(err).To(BeNil(), fmt.Sprintf("Error deleting Pod %v", err))
})
@ -126,7 +136,12 @@ var _ = framework.KubeDescribe("Kubelet", func() {
Context("when scheduling a busybox Pod with hostAliases", func() {
podName := "busybox-host-aliases" + string(uuid.NewUUID())
It("should write entries to /etc/hosts [NodeConformance]", func() {
/*
Release : v1.13
Testname: Kubelet, hostAliases
Description: Create a Pod with hostAliases and a container with command to output /etc/hosts entries. Pod's logs MUST have matching entries of specified hostAliases to the output of /etc/hosts entries.
*/
framework.ConformanceIt("should write entries to /etc/hosts [NodeConformance]", func() {
podClient.CreateSync(&v1.Pod{
ObjectMeta: metav1.ObjectMeta{
Name: podName,
@ -171,7 +186,12 @@ var _ = framework.KubeDescribe("Kubelet", func() {
Context("when scheduling a read only busybox container", func() {
podName := "busybox-readonly-fs" + string(uuid.NewUUID())
It("should not write to root filesystem [NodeConformance]", func() {
/*
Release : v1.13
Testname: Kubelet, pod with read only root file system
Description: Create a Pod with security context set with ReadOnlyRootFileSystem set to true. The Pod then tries to write to the /file on the root, write operation to the root filesystem MUST fail as expected.
*/
framework.ConformanceIt("should not write to root filesystem [NodeConformance]", func() {
isReadOnly := true
podClient.CreateSync(&v1.Pod{
ObjectMeta: metav1.ObjectMeta{