From bf57087a6e11ebc3917e2729335bf4de696ba5f1 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Thu, 24 Oct 2024 10:58:47 +0100 Subject: [PATCH] s3: fix testing tiers which don't exist except on AWS --- backend/s3/s3_test.go | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/backend/s3/s3_test.go b/backend/s3/s3_test.go index e0499ba66..6d00d8761 100644 --- a/backend/s3/s3_test.go +++ b/backend/s3/s3_test.go @@ -23,14 +23,20 @@ func SetupS3Test(t *testing.T) (context.Context, *Options, *http.Client) { // TestIntegration runs integration tests against the remote func TestIntegration(t *testing.T) { - fstests.Run(t, &fstests.Opt{ + opt := &fstests.Opt{ RemoteName: "TestS3:", NilObject: (*Object)(nil), - TiersToTest: []string{"STANDARD", "STANDARD_IA"}, + TiersToTest: []string{"STANDARD"}, ChunkedUpload: fstests.ChunkedUploadConfig{ MinChunkSize: minChunkSize, }, - }) + } + // Test wider range of tiers on AWS + if *fstest.RemoteName == "" || *fstest.RemoteName == "TestS3:" { + opt.TiersToTest = []string{"STANDARD", "STANDARD_IA"} + } + fstests.Run(t, opt) + } func TestIntegration2(t *testing.T) {