mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-24 19:38:02 +00:00
Extract testsuite api to a separate package
Extract TestSuite, TestDriver, TestPattern, TestConfig and VolumeResource, SnapshotVolumeResource from testsuite package and put them into a new package called api. The ultimate goal here is to make the testsuites as clean as possible. And only testsuites in the package.
This commit is contained in:
@@ -21,6 +21,7 @@ go_library(
|
||||
"//test/e2e/framework/pod:go_default_library",
|
||||
"//test/e2e/framework/pv:go_default_library",
|
||||
"//test/e2e/framework/skipper:go_default_library",
|
||||
"//test/e2e/framework/volume:go_default_library",
|
||||
"//test/e2e/storage/utils:go_default_library",
|
||||
"//test/e2e/upgrades:go_default_library",
|
||||
"//vendor/github.com/onsi/ginkgo:go_default_library",
|
||||
|
@@ -27,7 +27,8 @@ import (
|
||||
"k8s.io/kubernetes/test/e2e/framework"
|
||||
e2epod "k8s.io/kubernetes/test/e2e/framework/pod"
|
||||
e2epv "k8s.io/kubernetes/test/e2e/framework/pv"
|
||||
"k8s.io/kubernetes/test/e2e/storage/utils"
|
||||
e2evolume "k8s.io/kubernetes/test/e2e/framework/volume"
|
||||
storageutils "k8s.io/kubernetes/test/e2e/storage/utils"
|
||||
"k8s.io/kubernetes/test/e2e/upgrades"
|
||||
|
||||
"github.com/onsi/ginkgo"
|
||||
@@ -104,10 +105,10 @@ func (t *VolumeModeDowngradeTest) Setup(f *framework.Framework) {
|
||||
framework.ExpectNoError(err)
|
||||
|
||||
ginkgo.By("Checking if PV exists as expected volume mode")
|
||||
utils.CheckVolumeModeOfPath(f, t.pod, block, devicePath)
|
||||
e2evolume.CheckVolumeModeOfPath(f, t.pod, block, devicePath)
|
||||
|
||||
ginkgo.By("Checking if read/write to PV works properly")
|
||||
utils.CheckReadWriteToPath(f, t.pod, block, devicePath)
|
||||
storageutils.CheckReadWriteToPath(f, t.pod, block, devicePath)
|
||||
}
|
||||
|
||||
// Test waits for the downgrade to complete, and then verifies that a pod can no
|
||||
@@ -117,7 +118,7 @@ func (t *VolumeModeDowngradeTest) Test(f *framework.Framework, done <-chan struc
|
||||
<-done
|
||||
|
||||
ginkgo.By("Verifying that nothing exists at the device path in the pod")
|
||||
utils.VerifyExecInPodFail(f, t.pod, fmt.Sprintf("test -e %s", devicePath), 1)
|
||||
e2evolume.VerifyExecInPodFail(f, t.pod, fmt.Sprintf("test -e %s", devicePath), 1)
|
||||
}
|
||||
|
||||
// Teardown cleans up any remaining resources.
|
||||
|
Reference in New Issue
Block a user