Skip to content

fix some tests #184

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions oss2/xml_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,9 @@ def parse_get_bucket_info(result, body):

def _parse_bucket_encryption_info(node):

if node is None:
return None

rule = ServerSideEncryptionRule()

rule.sse_algorithm = _find_tag(node,"SSEAlgorithm")
Expand Down
2 changes: 2 additions & 0 deletions tests/test_bucket.py
Original file line number Diff line number Diff line change
Expand Up @@ -696,6 +696,7 @@ def test_bucket_encryption(self):
wait_meta_sync()

result = self.bucket.get_bucket_info()
self.assertTrue(result.bucket_encryption_rule is not None)
self.assertEqual(result.bucket_encryption_rule.sse_algorithm, 'AES256')
self.assertTrue(result.bucket_encryption_rule.kms_master_keyid is None)

Expand All @@ -720,6 +721,7 @@ def test_bucket_encryption(self):
wait_meta_sync()

result = self.bucket.get_bucket_info()
self.assertTrue(result.bucket_encryption_rule is not None)
self.assertEqual(result.bucket_encryption_rule.sse_algorithm, 'KMS')
self.assertTrue(result.bucket_encryption_rule.kms_master_keyid is None)

Expand Down