fix(deps): update stackit sdk modules (#903)
* fix(deps): update stackit sdk modules * Adjust git and mongodb regarding sdk changes Signed-off-by: Alexander Dahmen <alexander.dahmen@inovex.de> --------- Signed-off-by: Alexander Dahmen <alexander.dahmen@inovex.de> Co-authored-by: Renovate Bot <renovate@whitesourcesoftware.com> Co-authored-by: Alexander Dahmen <alexander.dahmen@inovex.de>
This commit is contained in:
parent
33b239a74d
commit
b32eedd4b4
6 changed files with 89 additions and 89 deletions
|
|
@ -406,7 +406,7 @@ func toCreatePayload(ctx context.Context, model *Model) (git.CreateInstancePaylo
|
|||
}
|
||||
|
||||
if !(model.Flavor.IsNull() || model.Flavor.IsUnknown()) {
|
||||
payload.Flavor = model.Flavor.ValueStringPointer()
|
||||
payload.Flavor = git.CreateInstancePayloadGetFlavorAttributeType(model.Flavor.ValueStringPointer())
|
||||
}
|
||||
|
||||
return payload, diags
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ func TestToCreatePayload(t *testing.T) {
|
|||
},
|
||||
expected: git.CreateInstancePayload{
|
||||
Name: utils.Ptr("my-instance"),
|
||||
Flavor: utils.Ptr("git-100"),
|
||||
Flavor: git.CREATEINSTANCEPAYLOADFLAVOR__100.Ptr(),
|
||||
Acl: &[]string{"10.0.0.1", "10.0.0.2"},
|
||||
},
|
||||
expectError: false,
|
||||
|
|
@ -187,12 +187,12 @@ func TestToCreatePayload(t *testing.T) {
|
|||
description: "empty ACL still valid",
|
||||
input: &Model{
|
||||
Name: types.StringValue("my-instance"),
|
||||
Flavor: types.StringValue("git-101"),
|
||||
Flavor: types.StringValue("git-100"),
|
||||
ACL: types.ListValueMust(types.StringType, []attr.Value{}),
|
||||
},
|
||||
expected: git.CreateInstancePayload{
|
||||
Name: utils.Ptr("my-instance"),
|
||||
Flavor: utils.Ptr("git-101"),
|
||||
Flavor: git.CREATEINSTANCEPAYLOADFLAVOR__100.Ptr(),
|
||||
Acl: &[]string{},
|
||||
},
|
||||
expectError: false,
|
||||
|
|
|
|||
|
|
@ -702,7 +702,7 @@ func (r *instanceResource) ImportState(ctx context.Context, req resource.ImportS
|
|||
tflog.Info(ctx, "MongoDB Flex instance state imported")
|
||||
}
|
||||
|
||||
func mapFields(ctx context.Context, resp *mongodbflex.GetInstanceResponse, model *Model, flavor *flavorModel, storage *storageModel, options *optionsModel, region string) error {
|
||||
func mapFields(ctx context.Context, resp *mongodbflex.InstanceResponse, model *Model, flavor *flavorModel, storage *storageModel, options *optionsModel, region string) error {
|
||||
if resp == nil {
|
||||
return fmt.Errorf("response input is nil")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ func TestMapFields(t *testing.T) {
|
|||
tests := []struct {
|
||||
description string
|
||||
state Model
|
||||
input *mongodbflex.GetInstanceResponse
|
||||
input *mongodbflex.InstanceResponse
|
||||
flavor *flavorModel
|
||||
storage *storageModel
|
||||
options *optionsModel
|
||||
|
|
@ -55,7 +55,7 @@ func TestMapFields(t *testing.T) {
|
|||
InstanceId: types.StringValue(instanceId),
|
||||
ProjectId: types.StringValue(projectId),
|
||||
},
|
||||
&mongodbflex.GetInstanceResponse{
|
||||
&mongodbflex.InstanceResponse{
|
||||
Item: &mongodbflex.Instance{},
|
||||
},
|
||||
&flavorModel{},
|
||||
|
|
@ -99,7 +99,7 @@ func TestMapFields(t *testing.T) {
|
|||
InstanceId: types.StringValue(instanceId),
|
||||
ProjectId: types.StringValue(projectId),
|
||||
},
|
||||
&mongodbflex.GetInstanceResponse{
|
||||
&mongodbflex.InstanceResponse{
|
||||
Item: &mongodbflex.Instance{
|
||||
Acl: &mongodbflex.ACL{
|
||||
Items: &[]string{
|
||||
|
|
@ -179,7 +179,7 @@ func TestMapFields(t *testing.T) {
|
|||
InstanceId: types.StringValue(instanceId),
|
||||
ProjectId: types.StringValue(projectId),
|
||||
},
|
||||
&mongodbflex.GetInstanceResponse{
|
||||
&mongodbflex.InstanceResponse{
|
||||
Item: &mongodbflex.Instance{
|
||||
Acl: &mongodbflex.ACL{
|
||||
Items: &[]string{
|
||||
|
|
@ -264,7 +264,7 @@ func TestMapFields(t *testing.T) {
|
|||
types.StringValue("ip1"),
|
||||
}),
|
||||
},
|
||||
&mongodbflex.GetInstanceResponse{
|
||||
&mongodbflex.InstanceResponse{
|
||||
Item: &mongodbflex.Instance{
|
||||
Acl: &mongodbflex.ACL{
|
||||
Items: &[]string{
|
||||
|
|
@ -358,7 +358,7 @@ func TestMapFields(t *testing.T) {
|
|||
InstanceId: types.StringValue(instanceId),
|
||||
ProjectId: types.StringValue(projectId),
|
||||
},
|
||||
&mongodbflex.GetInstanceResponse{},
|
||||
&mongodbflex.InstanceResponse{},
|
||||
&flavorModel{},
|
||||
&storageModel{},
|
||||
&optionsModel{},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue