Skip to content

Commit 133f772

Browse files
authored
Merge pull request kubernetes#87825 from kevtaylor/kep/VolumeSubpathExpansionE2ETests
Change HostPath to EmptyDir for VolumeSubpathEnvExpansion e2e tests
2 parents 4b29407 + 724fb73 commit 133f772

File tree

1 file changed

+9
-33
lines changed

1 file changed

+9
-33
lines changed

test/e2e/common/expansion.go

Lines changed: 9 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
184184
SubPathExpr: "$(POD_NAME)",
185185
},
186186
{
187-
Name: "workdir2",
187+
Name: "workdir1",
188188
MountPath: "/testcontainer",
189189
},
190190
},
@@ -195,13 +195,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
195195
{
196196
Name: "workdir1",
197197
VolumeSource: v1.VolumeSource{
198-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
199-
},
200-
},
201-
{
202-
Name: "workdir2",
203-
VolumeSource: v1.VolumeSource{
204-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
198+
EmptyDir: &v1.EmptyDirVolumeSource{},
205199
},
206200
},
207201
},
@@ -353,7 +347,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
353347
SubPathExpr: "$(ANNOTATION)/$(POD_NAME)",
354348
},
355349
{
356-
Name: "workdir2",
350+
Name: "workdir1",
357351
MountPath: "/volume_mount",
358352
},
359353
},
@@ -363,13 +357,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
363357
{
364358
Name: "workdir1",
365359
VolumeSource: v1.VolumeSource{
366-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
367-
},
368-
},
369-
{
370-
Name: "workdir2",
371-
VolumeSource: v1.VolumeSource{
372-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
360+
EmptyDir: &v1.EmptyDirVolumeSource{},
373361
},
374362
},
375363
},
@@ -443,7 +431,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
443431
SubPathExpr: "$(ANNOTATION)/$(POD_NAME)",
444432
},
445433
{
446-
Name: "workdir2",
434+
Name: "workdir1",
447435
MountPath: "/volume_mount",
448436
},
449437
},
@@ -454,13 +442,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
454442
{
455443
Name: "workdir1",
456444
VolumeSource: v1.VolumeSource{
457-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
458-
},
459-
},
460-
{
461-
Name: "workdir2",
462-
VolumeSource: v1.VolumeSource{
463-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
445+
EmptyDir: &v1.EmptyDirVolumeSource{},
464446
},
465447
},
466448
},
@@ -536,7 +518,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
536518
MountPath: "/subpath_mount",
537519
},
538520
{
539-
Name: "workdir2",
521+
Name: "workdir1",
540522
MountPath: "/volume_mount",
541523
},
542524
},
@@ -566,7 +548,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
566548
SubPathExpr: "$(POD_NAME)",
567549
},
568550
{
569-
Name: "workdir2",
551+
Name: "workdir1",
570552
MountPath: "/volume_mount",
571553
},
572554
},
@@ -577,13 +559,7 @@ var _ = framework.KubeDescribe("Variable Expansion", func() {
577559
{
578560
Name: "workdir1",
579561
VolumeSource: v1.VolumeSource{
580-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
581-
},
582-
},
583-
{
584-
Name: "workdir2",
585-
VolumeSource: v1.VolumeSource{
586-
HostPath: &v1.HostPathVolumeSource{Path: "/tmp"},
562+
EmptyDir: &v1.EmptyDirVolumeSource{},
587563
},
588564
},
589565
},

0 commit comments

Comments
 (0)