fix: fix flavor null ability
This commit is contained in:
parent
4ca2d6a05d
commit
70343b2193
2 changed files with 7 additions and 8 deletions
|
|
@ -85,7 +85,7 @@ type resData struct {
|
|||
Region string
|
||||
Name string
|
||||
TfName string
|
||||
FlavorID string
|
||||
FlavorID *string
|
||||
BackupSchedule string
|
||||
UseEncryption bool
|
||||
KekKeyID string
|
||||
|
|
@ -124,7 +124,7 @@ func getExample() resData {
|
|||
ProjectID: os.Getenv("TF_ACC_PROJECT_ID"),
|
||||
Name: name,
|
||||
TfName: name,
|
||||
FlavorID: singleFlavorID,
|
||||
FlavorID: utils.Ptr(singleFlavorID),
|
||||
BackupSchedule: "0 0 * * *",
|
||||
UseEncryption: false,
|
||||
RetentionDays: 33,
|
||||
|
|
@ -358,7 +358,7 @@ func TestAccInstance(t *testing.T) {
|
|||
|
||||
func TestAccInstanceHA(t *testing.T) {
|
||||
data := getExample()
|
||||
data.FlavorID = replicasFlavorID
|
||||
data.FlavorID = utils.Ptr(replicasFlavorID)
|
||||
data.Replicas = 3
|
||||
|
||||
testItemID := testutils.ResStr(pfx, "instance", data.TfName)
|
||||
|
|
@ -963,7 +963,7 @@ func getDatabaseTestID(name string) func(s *terraform.State) (string, error) {
|
|||
}
|
||||
}
|
||||
|
||||
func getUserTestID(name string) func(s *terraform.State) (string, error) {
|
||||
func getUserTestID(name string) func(s *teraform.State) (string, error) {
|
||||
return func(s *terraform.State) (string, error) {
|
||||
r, ok := s.RootModule().Resources[testutils.ResStr(pfx, "user", name)]
|
||||
if !ok {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue