Skip to content

Commit 912fd06

Browse files
committed
acctest: Add a check for the case when a non-existing quota_name is given
1 parent 415b934 commit 912fd06

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

internal/service/servicequotas/service_quota_data_source_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,10 @@ func TestAccServiceQuotasServiceQuotaDataSource_quotaName(t *testing.T) {
151151
ErrorCheck: acctest.ErrorCheck(t, names.ServiceQuotasServiceID),
152152
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories,
153153
Steps: []resource.TestStep{
154+
{
155+
Config: testAccServiceQuotaDataSourceConfig_name("vpc", setQuotaQuotaName+"nonexist"),
156+
ExpectError: regexache.MustCompile(`Service Quotas Service Quota`),
157+
},
154158
{
155159
Config: testAccServiceQuotaDataSourceConfig_name("vpc", setQuotaQuotaName),
156160
Check: resource.ComposeAggregateTestCheckFunc(

0 commit comments

Comments
 (0)