@@ -204,11 +204,15 @@ func TestAccScalewayRedisCluster_ACL(t *testing.T) {
204
204
resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "node_type" , "MDB-BETA-M" ),
205
205
resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "user_name" , "my_initial_user" ),
206
206
resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "password" , "thiZ_is_v&ry_s3cret" ),
207
- resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "acl.0.ip" , "0.0.0.0/0" ),
208
- resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "acl.0.description" , "An acl description" ),
207
+ resource .TestCheckTypeSetElemNestedAttrs ("scaleway_redis_cluster.main" , "acl.*" , map [string ]string {
208
+ "ip" : "0.0.0.0/0" ,
209
+ "description" : "An acl description" ,
210
+ }),
211
+ resource .TestCheckTypeSetElemNestedAttrs ("scaleway_redis_cluster.main" , "acl.*" , map [string ]string {
212
+ "ip" : "192.168.10.0/24" ,
213
+ "description" : "A second acl description" ,
214
+ }),
209
215
resource .TestCheckResourceAttrSet ("scaleway_redis_cluster.main" , "acl.0.id" ),
210
- resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "acl.1.ip" , "192.168.10.0/24" ),
211
- resource .TestCheckResourceAttr ("scaleway_redis_cluster.main" , "acl.1.description" , "A second acl description" ),
212
216
resource .TestCheckResourceAttrSet ("scaleway_redis_cluster.main" , "acl.1.id" ),
213
217
),
214
218
},
0 commit comments