@@ -17,12 +17,18 @@ type driverConfig struct {
17
17
SupportedFsType []string
18
18
MinimumVolumeSize string
19
19
NumAllowedTopologies int
20
+ Timeouts map [string ]string
20
21
}
21
22
22
23
const (
23
24
testConfigDir = "test/k8s-integration/config"
24
25
configTemplateFile = "test-config-template.in"
25
26
configFile = "test-config.yaml"
27
+ // configurable timeouts for the k8s e2e testsuites.
28
+ dataSourceProvisionTimeout = "480s"
29
+
30
+ // These are keys for the configurable timeout map.
31
+ dataSourceProvisionTimeoutKey = "DataSourceProvision"
26
32
)
27
33
28
34
// generateDriverConfigFile loads a testdriver config template and creates a file
@@ -123,6 +129,11 @@ func generateDriverConfigFile(testParams *testParameters, storageClassFile strin
123
129
minimumVolumeSize = "200Gi"
124
130
numAllowedTopologies = 2
125
131
}
132
+ // GCE PD CSI Driver takes in the order of minutes to provision storage with a pvc data source provisioned,
133
+ // and with dynamic provisioning (WaitForFirstCustomer policy), some e2e tests need a longer pod start timeout.
134
+ timeouts := map [string ]string {
135
+ dataSourceProvisionTimeoutKey : dataSourceProvisionTimeout ,
136
+ }
126
137
params := driverConfig {
127
138
StorageClassFile : filepath .Join (testParams .pkgDir , testConfigDir , storageClassFile ),
128
139
StorageClass : storageClassFile [:strings .LastIndex (storageClassFile , "." )],
@@ -131,6 +142,7 @@ func generateDriverConfigFile(testParams *testParameters, storageClassFile strin
131
142
Capabilities : caps ,
132
143
MinimumVolumeSize : minimumVolumeSize ,
133
144
NumAllowedTopologies : numAllowedTopologies ,
145
+ Timeouts : timeouts ,
134
146
}
135
147
136
148
// Write config file
0 commit comments