Currently, if we don’t specify int property and bool property in nested block in tfconfig, then we would get default int value “0” and default bool value “false” with d.get()/d.getok()/d.set().
example:
"testblock1": {
Type: schema.TypeList,
Required: true,
MaxItems: 1,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"testblock2": {
Type: schema.TypeList,
Optional: true,
MaxItems: 1,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"count": {
Type: schema.TypeInt,
Optional: true,
},
"enabled": {
Type: schema.TypeBool,
Optional: true,
},
},
},
},
},
},
},