Skip to content

Commit

Permalink
Fix failing build from botocore bucket validation
Browse files Browse the repository at this point in the history
We were creating bucket names that had a trailing '/'
which is wrong.
  • Loading branch information
jamesls committed Sep 3, 2015
1 parent 32c12c6 commit a3d052d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/integration/customizations/s3/test_s3handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ def tearDown(self):
def test_bucket(self):
rand1 = random.randrange(5000)
rand2 = random.randrange(5000)
self.bucket = str(rand1) + 'mybucket' + str(rand2) + '/'
self.bucket = str(rand1) + 'mybucket' + str(rand2)

file_info = FileInfo(
src=self.bucket, operation_name='make_bucket', size=0,
Expand All @@ -363,7 +363,7 @@ def test_bucket(self):
buckets_list = []
for bucket in self.client.list_buckets().get('Buckets', []):
buckets_list.append(bucket['Name'])
self.assertIn(self.bucket[:-1], buckets_list)
self.assertIn(self.bucket, buckets_list)

file_info = FileInfo(
src=self.bucket, operation_name='remove_bucket', size=0,
Expand All @@ -372,7 +372,7 @@ def test_bucket(self):
buckets_list = []
for bucket in self.client.list_buckets().get('Buckets', []):
buckets_list.append(bucket['Name'])
self.assertNotIn(self.bucket[:-1], buckets_list)
self.assertNotIn(self.bucket, buckets_list)


if __name__ == "__main__":
Expand Down

0 comments on commit a3d052d

Please sign in to comment.