Skip to content

Commit cbbf3a0

Browse files
hcsa73Henrique Santos
andauthored
SKE Acc tests - Remove max_surge from min cluster (#130)
* Remove max_surge * Simplify import --------- Co-authored-by: Henrique Santos <[email protected]>
1 parent 4728a49 commit cbbf3a0

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

stackit/internal/services/ske/ske_acc_test.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
"github.com/hashicorp/terraform-plugin-testing/helper/resource"
1111
"github.com/hashicorp/terraform-plugin-testing/terraform"
1212
"github.com/stackitcloud/stackit-sdk-go/core/config"
13-
oapiError "github.com/stackitcloud/stackit-sdk-go/core/oapierror"
13+
"github.com/stackitcloud/stackit-sdk-go/core/oapierror"
1414
"github.com/stackitcloud/stackit-sdk-go/core/utils"
1515
"github.com/stackitcloud/stackit-sdk-go/services/ske"
1616
"github.com/stackitcloud/stackit-sdk-go/services/ske/wait"
@@ -143,7 +143,6 @@ func getConfig(version string, apc *bool, maintenanceEnd *string) string {
143143
os_version = "%s"
144144
minimum = "%s"
145145
maximum = "%s"
146-
max_surge = "%s"
147146
availability_zones = ["%s"]
148147
}]
149148
maintenance = {
@@ -196,7 +195,6 @@ func getConfig(version string, apc *bool, maintenanceEnd *string) string {
196195
clusterResource["nodepool_os_version_min"],
197196
clusterResource["nodepool_minimum"],
198197
clusterResource["nodepool_maximum"],
199-
clusterResource["nodepool_max_surge"],
200198
clusterResource["nodepool_zone"],
201199
clusterResource["maintenance_enable_kubernetes_version_updates"],
202200
clusterResource["maintenance_enable_machine_image_version_updates"],
@@ -531,7 +529,7 @@ func testAccCheckSKEDestroy(s *terraform.State) error {
531529
for _, projectId := range projectsToDestroy {
532530
_, err := client.GetProject(ctx, projectId).Execute()
533531
if err != nil {
534-
oapiErr, ok := err.(*oapiError.GenericOpenAPIError) //nolint:errorlint //complaining that error.As should be used to catch wrapped errors, but this error should not be wrapped
532+
oapiErr, ok := err.(*oapierror.GenericOpenAPIError) //nolint:errorlint //complaining that error.As should be used to catch wrapped errors, but this error should not be wrapped
535533
if !ok {
536534
return fmt.Errorf("could not convert error to GenericOpenApiError in acc test destruction, %w", err)
537535
}

0 commit comments

Comments
 (0)