Skip to content
This repository was archived by the owner on Sep 8, 2025. It is now read-only.

Commit 77ec783

Browse files
Merge pull request #2 from matthewhartstonge/dependabot/go_modules/github.com/hashicorp/terraform-plugin-framework-0.14.0
chore(deps): bump github.com/hashicorp/terraform-plugin-framework from 0.13.0 to 0.14.0
2 parents 72743a5 + ef1fcf5 commit 77ec783

File tree

4 files changed

+42
-3
lines changed

4 files changed

+42
-3
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ go 1.18
55
require (
66
github.com/google/go-cmp v0.5.9
77
github.com/google/uuid v1.3.0
8-
github.com/hashicorp/terraform-plugin-framework v0.13.0
8+
github.com/hashicorp/terraform-plugin-framework v0.14.0
99
github.com/hashicorp/terraform-plugin-go v0.14.0
1010
)
1111

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38=
99
github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
1010
github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I=
1111
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
12-
github.com/hashicorp/terraform-plugin-framework v0.13.0 h1:tGnqttzZwU3FKc+HasHr2Yi5L81FcQbdc8zQhbBD9jQ=
13-
github.com/hashicorp/terraform-plugin-framework v0.13.0/go.mod h1:wcZdk4+Uef6Ng+BiBJjGAcIPlIs5bhlEV/TA1k6Xkq8=
12+
github.com/hashicorp/terraform-plugin-framework v0.14.0 h1:Mwj55u+Jc/QGM6fLBPCe1P+ZF3cuYs6wbCdB15lx/Dg=
13+
github.com/hashicorp/terraform-plugin-framework v0.14.0/go.mod h1:wcZdk4+Uef6Ng+BiBJjGAcIPlIs5bhlEV/TA1k6Xkq8=
1414
github.com/hashicorp/terraform-plugin-go v0.14.0 h1:ttnSlS8bz3ZPYbMb84DpcPhY4F5DsQtcAS7cHo8uvP4=
1515
github.com/hashicorp/terraform-plugin-go v0.14.0/go.mod h1:2nNCBeRLaenyQEi78xrGrs9hMbulveqG/zDMQSvVJTE=
1616
github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI=

uuidtypes/uuid_type.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,3 +110,8 @@ func (u UUIDType) ValueFromTerraform(_ context.Context, value tftypes.Value) (at
110110

111111
return UUIDFromGoogleUUID(parsedUUID), nil
112112
}
113+
114+
// ValueType returns attr.Value type returned by ValueFromTerraform.
115+
func (u UUIDType) ValueType(context.Context) attr.Value {
116+
return UUID{}
117+
}

uuidtypes/uuid_type_test.go

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -412,3 +412,37 @@ func TestType_ValueFromTerraform(t *testing.T) {
412412
})
413413
}
414414
}
415+
416+
func TestUUIDType_ValueType(t *testing.T) {
417+
t.Parallel()
418+
419+
tests := []struct {
420+
name string
421+
value uuidtypes.UUIDType
422+
expected attr.Value
423+
}{
424+
{
425+
name: "always",
426+
value: uuidtypes.UUIDType{},
427+
expected: uuidtypes.UUID{},
428+
},
429+
}
430+
for _, testcase := range tests {
431+
testcase := testcase
432+
433+
t.Run(testcase.name, func(t *testing.T) {
434+
t.Parallel()
435+
436+
got := testcase.value.ValueType(context.Background())
437+
438+
if diff := cmp.Diff(got, testcase.expected); diff != "" {
439+
t.Errorf(
440+
"Type()\ngot : %v\nexpected: %v\ndiff: %v\n",
441+
got,
442+
testcase.expected,
443+
diff,
444+
)
445+
}
446+
})
447+
}
448+
}

0 commit comments

Comments
 (0)