mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-17 11:50:18 +00:00
e2e: provide an option to skip rbd and cephfs e2e
Added two new parameters for e2e test to skip rbd and cephfs tests. This will help us to run more test in Travis CI. Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
parent
4e82384b43
commit
63b795d165
@ -78,6 +78,8 @@ are available while running tests:
|
||||
| deploy-timeout | Timeout to wait for created kubernetes resources (default: 10 minutes) |
|
||||
| deploy-cephfs | Deploy cephfs csi driver as part of E2E (default: true) |
|
||||
| deploy-rbd | Deploy rbd csi driver as part of E2E (default: true) |
|
||||
| test-cephfs | Test cephfs csi driver as part of E2E (default: true) |
|
||||
| test-rbd | Test rbd csi driver as part of E2E (default: true) |
|
||||
| cephcsi-namespace | The namespace in which cephcsi driver will be created (default: "default") |
|
||||
| rook-namespace | The namespace in which rook operator is installed (default: "rook-ceph") |
|
||||
| kubeconfig | Path to kubeconfig containing embedded authinfo (default: $HOME/.kube/config) |
|
||||
|
@ -115,6 +115,9 @@ var _ = Describe("cephfs", func() {
|
||||
var c clientset.Interface
|
||||
// deploy cephfs CSI
|
||||
BeforeEach(func() {
|
||||
if !testCephFS {
|
||||
Skip("Skipping CephFS E2E")
|
||||
}
|
||||
c = f.ClientSet
|
||||
if deployCephFS {
|
||||
if cephCSINamespace != defaultNs {
|
||||
@ -130,6 +133,9 @@ var _ = Describe("cephfs", func() {
|
||||
})
|
||||
|
||||
AfterEach(func() {
|
||||
if !testRBD {
|
||||
Skip("Skipping CephFS E2E")
|
||||
}
|
||||
if CurrentGinkgoTestDescription().Failed {
|
||||
// log pods created by helm chart
|
||||
logsCSIPods("app=ceph-csi-cephfs", c)
|
||||
|
@ -20,6 +20,8 @@ func init() {
|
||||
flag.IntVar(&deployTimeout, "deploy-timeout", 10, "timeout to wait for created kubernetes resources")
|
||||
flag.BoolVar(&deployCephFS, "deploy-cephfs", true, "deploy cephfs csi driver")
|
||||
flag.BoolVar(&deployRBD, "deploy-rbd", true, "deploy rbd csi driver")
|
||||
flag.BoolVar(&testCephFS, "test-cephfs", true, "test cephfs csi driver")
|
||||
flag.BoolVar(&testRBD, "test-rbd", true, "test rbd csi driver")
|
||||
flag.StringVar(&cephCSINamespace, "cephcsi-namespace", defaultNs, "namespace in which cephcsi deployed")
|
||||
flag.StringVar(&rookNamespace, "rook-namespace", "rook-ceph", "namespace in which rook is deployed")
|
||||
setDefaultKubeconfig()
|
||||
|
@ -128,6 +128,9 @@ var _ = Describe("RBD", func() {
|
||||
var c clientset.Interface
|
||||
// deploy RBD CSI
|
||||
BeforeEach(func() {
|
||||
if !testRBD {
|
||||
Skip("Skipping RBD E2E")
|
||||
}
|
||||
c = f.ClientSet
|
||||
if deployRBD {
|
||||
createNodeLabel(f, nodeRegionLabel, regionValue)
|
||||
@ -147,6 +150,9 @@ var _ = Describe("RBD", func() {
|
||||
})
|
||||
|
||||
AfterEach(func() {
|
||||
if !testRBD {
|
||||
Skip("Skipping RBD E2E")
|
||||
}
|
||||
if CurrentGinkgoTestDescription().Failed {
|
||||
// log pods created by helm chart
|
||||
logsCSIPods("app=ceph-csi-rbd", c)
|
||||
|
@ -52,6 +52,8 @@ var (
|
||||
deployTimeout int
|
||||
deployCephFS bool
|
||||
deployRBD bool
|
||||
testCephFS bool
|
||||
testRBD bool
|
||||
cephCSINamespace string
|
||||
rookNamespace string
|
||||
ns string
|
||||
|
Loading…
Reference in New Issue
Block a user