Skip to content

Commit 45b23af

Browse files
committed
forgot one, oops
1 parent ccc33e8 commit 45b23af

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

querycheck/expect_known_value_test.go

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,30 @@ func TestExpectKnownValue(t *testing.T) {
3434
},
3535
})
3636
}
37+
38+
// Let's add a test case that checks the failure scenario when the value is incorrect.
39+
func TestExpectKnownValue_ValueIncorrect(t *testing.T) {
40+
t.Parallel()
41+
42+
r.UnitTest(t, r.TestCase{
43+
TerraformVersionChecks: []tfversion.TerraformVersionCheck{
44+
tfversion.SkipBelow(tfversion.Version1_14_0),
45+
},
46+
ProtoV6ProviderFactories: map[string]func() (tfprotov6.ProviderServer, error){
47+
"examplecloud": providerserver.NewProviderServer(testprovider.Provider{
48+
ListResources: map[string]testprovider.ListResource{
49+
50+
// TODO: define a simpler resource and list resource here or copy the `examplecloud_test.go` and `examplecloud_list_resource.go` files here for use
51+
52+
//"examplecloud_containerette": examplecloudListResource(),
53+
},
54+
Resources: map[string]testprovider.Resource{
55+
//"examplecloud_containerette": examplecloudResource(),
56+
},
57+
}),
58+
},
59+
Steps: []r.TestStep{
60+
// TODO
61+
},
62+
})
63+
}

0 commit comments

Comments
 (0)