예제 #1
0
 def test_bucket_details_view_without_versioning(self):
     request = self.create_request()
     bucket, bucket_acl = self.make_bucket()
     view = BucketDetailsView(request, bucket=bucket, bucket_acl=bucket_acl).bucket_details()
     self.assertEqual(view.get('bucket_name'), 'test_bucket')
     self.assertEqual(view.get('bucket_contents_url'), '/buckets/test_bucket/contents/')
     self.assertEqual(view.get('versioning_status'), 'Disabled')
     self.assertEqual(view.get('update_versioning_action'), 'enable')
예제 #2
0
 def test_bucket_details_view_without_versioning(self):
     request = self.create_request()
     bucket, bucket_acl = self.make_bucket()
     view = BucketDetailsView(request, bucket=bucket, bucket_acl=bucket_acl).bucket_details()
     self.assertEqual(view.get("bucket_name"), "test_bucket")
     self.assertEqual(view.get("bucket_contents_url"), "/buckets/test_bucket/contents/")
     self.assertEqual(view.get("versioning_status"), "Disabled")
     self.assertEqual(view.get("update_versioning_action"), "enable")
예제 #3
0
 def test_bucket_details_view_without_versioning(self):
     request = self.create_request()
     self.setup_session(request)
     request.matchdict['name'] = 'test_bucket'
     self.make_bucket()
     view = BucketDetailsView(request).bucket_details()
     self.assertEqual(view.get('bucket_name'), 'test_bucket')
     self.assertEqual(view.get('bucket_contents_url'), '/buckets/test_bucket/contents/')
     self.assertEqual(view.get('versioning_status'), 'Disabled')
     self.assertEqual(view.get('update_versioning_action'), 'enable')
예제 #4
0
 def test_bucket_details_view_without_versioning(self):
     request = self.create_request()
     self.setup_session(request)
     request.matchdict['name'] = 'test_bucket'
     self.make_bucket()
     view = BucketDetailsView(request).bucket_details()
     self.assertEqual(view.get('bucket_name'), 'test_bucket')
     self.assertEqual(view.get('bucket_contents_url'),
                      '/buckets/test_bucket/contents/')
     self.assertEqual(view.get('versioning_status'), 'Disabled')
     self.assertEqual(view.get('update_versioning_action'), 'enable')