0

What should I do if some S3 integration tests fail? Could find any helpful solution on the Internet. Only -DBUILD_ONLY="s3" compilation parameter was used. The repo os on 1.0.99 tag. Here is the log of ./aws-cpp-sdk-s3-integration-tests:

[==========] Running 8 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 8 tests from BucketAndObjectOperationTest
[ RUN      ] BucketAndObjectOperationTest.TestInterrupt
/home/user/workspace/aws-sdk-cpp/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp:317: Failure
Value of: createBucketOutcome.IsSuccess()
  Actual: false
Expected: true
[  FAILED  ] BucketAndObjectOperationTest.TestInterrupt (580 ms)
[ RUN      ] BucketAndObjectOperationTest.TestBucketCreationAndListing
[       OK ] BucketAndObjectOperationTest.TestBucketCreationAndListing (1057 ms)
[ RUN      ] BucketAndObjectOperationTest.TestBucketLocation
[       OK ] BucketAndObjectOperationTest.TestBucketLocation (1756 ms)
[ RUN      ] BucketAndObjectOperationTest.TestObjectOperations
/home/user/workspace/aws-sdk-cpp/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp:468: Failure
Value of: createBucketOutcome.IsSuccess()
  Actual: false
Expected: true
[  FAILED  ] BucketAndObjectOperationTest.TestObjectOperations (110 ms)
[ RUN      ] BucketAndObjectOperationTest.TestKeysWithCrazyCharacterSets
/home/user/workspace/aws-sdk-cpp/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp:547: Failure
Value of: createBucketOutcome.IsSuccess()
  Actual: false
Expected: true
[  FAILED  ] BucketAndObjectOperationTest.TestKeysWithCrazyCharacterSets (121 ms)
[ RUN      ] BucketAndObjectOperationTest.TestObjectOperationsWithPresignedUrls
/home/user/workspace/aws-sdk-cpp/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp:641: Failure
Value of: createBucketOutcome.IsSuccess()
  Actual: false
Expected: true
[  FAILED  ] BucketAndObjectOperationTest.TestObjectOperationsWithPresignedUrls (116 ms)
[ RUN      ] BucketAndObjectOperationTest.TestMultiPartObjectOperations
[       OK ] BucketAndObjectOperationTest.TestMultiPartObjectOperations (23499 ms)
[ RUN      ] BucketAndObjectOperationTest.TestThatErrorsParse
[       OK ] BucketAndObjectOperationTest.TestThatErrorsParse (667 ms)
[----------] 8 tests from BucketAndObjectOperationTest (27907 ms total)

[----------] Global test environment tear-down
[==========] 8 tests from 1 test case ran. (29961 ms total)
[  PASSED  ] 4 tests.
[  FAILED  ] 4 tests, listed below:
[  FAILED  ] BucketAndObjectOperationTest.TestInterrupt
[  FAILED  ] BucketAndObjectOperationTest.TestObjectOperations
[  FAILED  ] BucketAndObjectOperationTest.TestKeysWithCrazyCharacterSets
[  FAILED  ] BucketAndObjectOperationTest.TestObjectOperationsWithPresignedUrls

 4 FAILED TESTS

1 Answers1

0

Prior to v1.0.122, s3 integration tests used fixed bucket names.

Since S3 bucket names are globally unique, if someone anywhere in the world ran the integration tests and aborted them half way, the tear-down/cleanup code won't run, and the buckets created with the fixed names will live under that account. That will cause the integration tests to fail for everyone else.

v1.0.122+ fixes that problem by using random suffixes appended to bucket names.

Marco M.
  • 2,956
  • 2
  • 29
  • 22