forked from bsteciuk/kismatic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstorage_test.go
48 lines (42 loc) · 1.5 KB
/
storage_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
package integration
import (
"os"
. "github.com/onsi/ginkgo"
)
var _ = Describe("Storage feature", func() {
BeforeEach(func() {
dir := setupTestWorkingDir()
os.Chdir(dir)
})
Describe("Specifying multiple storage nodes in the plan file", func() {
Context("when targeting CentOS", func() {
ItOnAWS("should result in a working storage cluster [slow]", func(aws infrastructureProvisioner) {
testAddVolumeVerifyGluster(aws, CentOS7)
})
})
Context("when targeting Ubuntu", func() {
ItOnAWS("should result in a working storage cluster [slow]", func(aws infrastructureProvisioner) {
testAddVolumeVerifyGluster(aws, Ubuntu1604LTS)
})
})
Context("when targeting RHEL", func() {
ItOnAWS("should result in a working storage cluster [slow]", func(aws infrastructureProvisioner) {
testAddVolumeVerifyGluster(aws, RedHat7)
})
})
})
Describe("Deploying a stateful workload", func() {
Context("on a cluster with storage nodes", func() {
ItOnAWS("should be able to read/write to a persistent volume [slow]", func(aws infrastructureProvisioner) {
WithInfrastructure(NodeCount{Etcd: 1, Master: 1, Worker: 2, Storage: 2}, Ubuntu1604LTS, aws, func(nodes provisionedNodes, sshKey string) {
By("Installing a cluster with storage")
opts := installOptions{}
err := installKismatic(nodes, opts, sshKey)
FailIfError(err, "Installation failed")
err = testStatefulWorkload(nodes, sshKey)
FailIfError(err, "Stateful workload test failed")
})
})
})
})
})