@@ -51,7 +51,7 @@ func TestAccObject_Basic(t *testing.T) {
5151 ` , bucketName , objectTestsMainRegion ),
5252 Check : resource .ComposeTestCheckFunc (
5353 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
54- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
54+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
5555 ),
5656 },
5757 {
@@ -72,7 +72,7 @@ func TestAccObject_Basic(t *testing.T) {
7272 ` , bucketName , objectTestsMainRegion ),
7373 Check : resource .ComposeTestCheckFunc (
7474 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
75- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
75+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
7676 ),
7777 },
7878 {
@@ -93,7 +93,7 @@ func TestAccObject_Basic(t *testing.T) {
9393 ` , bucketName , objectTestsMainRegion ),
9494 Check : resource .ComposeTestCheckFunc (
9595 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
96- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
96+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
9797 ),
9898 },
9999 },
@@ -131,7 +131,7 @@ func TestAccObject_ContentType(t *testing.T) {
131131 ` , bucketName , objectTestsMainRegion ),
132132 Check : resource .ComposeTestCheckFunc (
133133 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.main" , true ),
134- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
134+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
135135 resource .TestCheckResourceAttr ("scaleway_object.file" , "content_type" , "text/html" ),
136136 ),
137137 },
@@ -171,7 +171,7 @@ func TestAccObject_Hash(t *testing.T) {
171171 ` , bucketName , objectTestsMainRegion ),
172172 Check : resource .ComposeTestCheckFunc (
173173 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
174- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
174+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
175175 ),
176176 },
177177 {
@@ -193,7 +193,7 @@ func TestAccObject_Hash(t *testing.T) {
193193 ` , bucketName , objectTestsMainRegion ),
194194 Check : resource .ComposeTestCheckFunc (
195195 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
196- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
196+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
197197 ),
198198 },
199199 },
@@ -231,7 +231,7 @@ func TestAccObject_Move(t *testing.T) {
231231 ` , bucketName , objectTestsMainRegion ),
232232 Check : resource .ComposeTestCheckFunc (
233233 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
234- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" )),
234+ objectchecks .IsObjectExists (tt , "scaleway_object.file" )),
235235 },
236236 {
237237 Config : fmt .Sprintf (`
@@ -251,7 +251,7 @@ func TestAccObject_Move(t *testing.T) {
251251 ` , bucketName , objectTestsMainRegion ),
252252 Check : resource .ComposeTestCheckFunc (
253253 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
254- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" )),
254+ objectchecks .IsObjectExists (tt , "scaleway_object.file" )),
255255 },
256256 },
257257 })
@@ -290,7 +290,7 @@ func TestAccObject_StorageClass(t *testing.T) {
290290 ` , bucketName , objectTestsMainRegion ),
291291 Check : resource .ComposeTestCheckFunc (
292292 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
293- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
293+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
294294 resource .TestCheckResourceAttr ("scaleway_object.file" , "storage_class" , "ONEZONE_IA" ),
295295 ),
296296 },
@@ -314,7 +314,7 @@ func TestAccObject_StorageClass(t *testing.T) {
314314 ` , bucketName , objectTestsMainRegion ),
315315 Check : resource .ComposeTestCheckFunc (
316316 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
317- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
317+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
318318 resource .TestCheckResourceAttr ("scaleway_object.file" , "storage_class" , "STANDARD" ),
319319 ),
320320 },
@@ -357,7 +357,7 @@ func TestAccObject_Metadata(t *testing.T) {
357357 ` , bucketName , objectTestsMainRegion ),
358358 Check : resource .ComposeTestCheckFunc (
359359 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
360- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
360+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
361361 resource .TestCheckResourceAttr ("scaleway_object.file" , "metadata.key" , "value" ),
362362 ),
363363 },
@@ -384,7 +384,7 @@ func TestAccObject_Metadata(t *testing.T) {
384384 ` , bucketName , objectTestsMainRegion ),
385385 Check : resource .ComposeTestCheckFunc (
386386 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
387- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
387+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
388388 resource .TestCheckResourceAttr ("scaleway_object.file" , "metadata.key" , "other_value" ),
389389 resource .TestCheckResourceAttr ("scaleway_object.file" , "metadata.other_key" , "VALUE" ),
390390 ),
@@ -425,7 +425,7 @@ func TestAccObject_Tags(t *testing.T) {
425425 ` , bucketName , objectTestsMainRegion ),
426426 Check : resource .ComposeTestCheckFunc (
427427 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
428- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
428+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
429429 resource .TestCheckResourceAttr ("scaleway_object.file" , "tags.key" , "value" ),
430430 ),
431431 },
@@ -449,7 +449,7 @@ func TestAccObject_Tags(t *testing.T) {
449449 ` , bucketName , objectTestsMainRegion ),
450450 Check : resource .ComposeTestCheckFunc (
451451 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
452- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
452+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
453453 resource .TestCheckResourceAttr ("scaleway_object.file" , "tags.key" , "other_value" ),
454454 resource .TestCheckResourceAttr ("scaleway_object.file" , "tags.other_key" , "VALUE" ),
455455 ),
@@ -488,7 +488,7 @@ func TestAccObject_Visibility(t *testing.T) {
488488 ` , bucketName , objectTestsMainRegion ),
489489 Check : resource .ComposeTestCheckFunc (
490490 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
491- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
491+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
492492 resource .TestCheckResourceAttr ("scaleway_object.file" , "visibility" , "public-read" ),
493493 ),
494494 },
@@ -509,7 +509,7 @@ func TestAccObject_Visibility(t *testing.T) {
509509 ` , bucketName , objectTestsMainRegion ),
510510 Check : resource .ComposeTestCheckFunc (
511511 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
512- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
512+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
513513 resource .TestCheckResourceAttr ("scaleway_object.file" , "visibility" , "private" ),
514514 ),
515515 },
@@ -547,7 +547,7 @@ func TestAccObject_State(t *testing.T) {
547547 ` , bucketName , objectTestsMainRegion ),
548548 Check : resource .ComposeTestCheckFunc (
549549 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
550- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
550+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
551551 ),
552552 },
553553 {
@@ -575,8 +575,8 @@ func TestAccObject_State(t *testing.T) {
575575 ImportStateId : fmt .Sprintf ("%s/%s/myfile" , objectTestsMainRegion , bucketName ),
576576 Check : resource .ComposeTestCheckFunc (
577577 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
578- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
579- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file_imported" ),
578+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
579+ objectchecks .IsObjectExists (tt , "scaleway_object.file_imported" ),
580580 resource .TestCheckResourceAttrPair ("scaleway_object.file_imported" , "id" , "scaleway_object.file" , "id" ),
581581 resource .TestCheckResourceAttrPair ("scaleway_object.file_imported" , "visibility" , "scaleway_object.file" , "visibility" ),
582582 resource .TestCheckResourceAttrPair ("scaleway_object.file_imported" , "bucket" , "scaleway_object.file" , "bucket" ),
@@ -619,7 +619,7 @@ func TestAccObject_ByContent(t *testing.T) {
619619 ` , bucketName , objectTestsMainRegion , fileContentStep1 ),
620620 Check : resource .ComposeTestCheckFunc (
621621 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
622- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.by-content" ),
622+ objectchecks .IsObjectExists (tt , "scaleway_object.by-content" ),
623623 resource .TestCheckResourceAttr ("scaleway_object.by-content" , "content" , fileContentStep1 ),
624624 ),
625625 },
@@ -638,7 +638,7 @@ func TestAccObject_ByContent(t *testing.T) {
638638 ` , bucketName , objectTestsMainRegion , fileContentStep2 ),
639639 Check : resource .ComposeTestCheckFunc (
640640 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
641- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.by-content" ),
641+ objectchecks .IsObjectExists (tt , "scaleway_object.by-content" ),
642642 resource .TestCheckResourceAttr ("scaleway_object.by-content" , "content" , fileContentStep2 ),
643643 ),
644644 },
@@ -680,7 +680,7 @@ func TestAccObject_ByContentBase64(t *testing.T) {
680680 ` , bucketName , objectTestsMainRegion , fileContentStep1 ),
681681 Check : resource .ComposeTestCheckFunc (
682682 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
683- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.by-content-base64" ),
683+ objectchecks .IsObjectExists (tt , "scaleway_object.by-content-base64" ),
684684 resource .TestCheckResourceAttr ("scaleway_object.by-content-base64" , "content_base64" , fileEncodedStep1 ),
685685 ),
686686 },
@@ -699,7 +699,7 @@ func TestAccObject_ByContentBase64(t *testing.T) {
699699 ` , bucketName , objectTestsMainRegion , fileContentStep2 ),
700700 Check : resource .ComposeTestCheckFunc (
701701 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
702- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.by-content-base64" ),
702+ objectchecks .IsObjectExists (tt , "scaleway_object.by-content-base64" ),
703703 resource .TestCheckResourceAttr ("scaleway_object.by-content-base64" , "content_base64" , fileEncodedStep2 ),
704704 ),
705705 },
@@ -772,7 +772,7 @@ func TestAccObject_WithBucketName(t *testing.T) {
772772 ` , bucketName , objectTestsMainRegion ),
773773 Check : resource .ComposeTestCheckFunc (
774774 objectchecks .CheckBucketExists (tt , "scaleway_object_bucket.base-01" , true ),
775- objectchecks .TestAccCheckObjectExists (tt , "scaleway_object.file" ),
775+ objectchecks .IsObjectExists (tt , "scaleway_object.file" ),
776776 ),
777777 },
778778 },
0 commit comments