Class AwsTestHelper


  • public class AwsTestHelper
    extends Object
    • Constructor Detail

      • AwsTestHelper

        public AwsTestHelper()
    • Method Detail

      • getAwsCredentials

        public static com.amazonaws.auth.AWSCredentials getAwsCredentials()
        Get AWS credentials from environment/properties/profile/instance profile
      • getDefaultRegion

        public static com.amazonaws.regions.Regions getDefaultRegion()
        Get default AWS region for tests
      • newS3Client

        @NotNull
        public static @NotNull com.atlassian.aws.s3.BambooAmazonS3Client newS3Client()
        Create S3 client using default credentials and region
      • newS3Client

        @NotNull
        public static @NotNull com.atlassian.aws.s3.BambooAmazonS3Client newS3Client​(@NotNull
                                                                                     @NotNull com.amazonaws.auth.AWSCredentials awsCredentials)
        Create S3 client using given credentials and default region
      • createBucket

        public static com.amazonaws.services.s3.model.Bucket createBucket​(@NotNull
                                                                          @NotNull String bucketName)
      • deleteBucket

        public static void deleteBucket​(@NotNull
                                        @NotNull String bucketName)