Skip to content

Commit

Permalink
Dont list buckets in s3 tests (#318)
Browse files Browse the repository at this point in the history
* Don't attempt to list all buckets in s3 tests

The tests used a ListBuckets operation which requires privileges that
I'm not comfortable giving to Travis, and which aren't actually
necessary.  We know what the bucket name is so we don't need to scan
each and every bucket, we can just open the one we want.

Also removed an if/then on test bucket creation which caused race
conditions.

* Reduce create/delete bucket churn in s3 tests

The s3 tests were deleting and creating the same bucket over and over
which isn't necessary - we now create the bucket once before the tests
run and delete it after they're done.  This is a little faster and
appears to reduce the number of race conditions that we hit.

* Respond to code review comments

#318 (review)

 - No more global "s3" handle - allocate one locally when needed

 - Document setUpModule and tearDownModule

 - Document when we create/delete the test bucket

 - Put populate_bucket back where it was

 - Call cleanup_bucket after each test
  • Loading branch information
toby cabot authored and mpenkov committed May 29, 2019
1 parent 5f730f2 commit 86964ad
Showing 1 changed file with 70 additions and 80 deletions.

0 comments on commit 86964ad

Please sign in to comment.