Skip to content
Merged
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
4 changes: 2 additions & 2 deletions tests/test_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -1071,7 +1071,7 @@ def test_enforce_patch_override_success(self):
def test_crc32c_to_from_proto(self):
# used an external tool to get the CRC32C of:
# /bin/echo -n 'The quick brown fox jumps over the lazy dog' > fox.txt
# gsutil hash fox.txt
# gcloud storage hash fox.txt
# it prints
# Hash (crc32c): ImIEBA==
# then use:
Expand All @@ -1086,7 +1086,7 @@ def test_crc32c_to_from_proto(self):
def test_md5_to_from_proto(self):
# used an external tool to get the CRC32C of:
# /bin/echo -n 'The quick brown fox jumps over the lazy dog' > fox.txt
# gsutil hash fox.txt
# gcloud storage hash fox.txt
# it prints
# Hash (md5): nhB9nTcrtoJr2B01QqQZ1g==
# then use:
Expand Down
8 changes: 4 additions & 4 deletions tests/test_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ def test_init_multipart_inconsistent_content_type(self):
self.assertEqual(rest.exception.code, 412)

def test_init_multipart_inconsistent_md5(self):
# The magic string is the MD5 hash for an empty object, computed using `gsutil hash`
# The magic string is the MD5 hash for an empty object, computed using `gcloud storage hash`
boundary, payload = format_multipart_upload(
{"name": "object", "md5Hash": "1B2M2Y8AsgTpgAmY7PhCfg=="},
"How vexingly quick daft zebras jump!",
Expand All @@ -219,7 +219,7 @@ def test_init_multipart_inconsistent_md5(self):
self.assertEqual(rest.exception.code, 412)

def test_init_multipart_inconsistent_crc32c(self):
# The magic string is the CRC32C checksum for an empty object, computed using `gsutil hash`
# The magic string is the CRC32C checksum for an empty object, computed using `gcloud storage hash`
boundary, payload = format_multipart_upload(
{"name": "object", "crc32c": "AAAAAA=="},
"How vexingly quick daft zebras jump!",
Expand All @@ -241,7 +241,7 @@ def test_init_xml_md5hash(self):
base_url="http://localhost:8080",
content_type="text/plain",
headers={
# This MD5 hash was obtained using `gsutil hash`
# This MD5 hash was obtained using `gcloud storage hash`
"x-goog-hash": "md5=nhB9nTcrtoJr2B01QqQZ1g==",
},
content_length=len(media),
Expand All @@ -260,7 +260,7 @@ def test_init_xml_crc32c(self):
base_url="http://localhost:8080",
content_type="text/plain",
headers={
# This CRC32C checksum was obtained using `gsutil hash`
# This CRC32C checksum was obtained using `gcloud storage hash`
"x-goog-hash": "crc32c=ImIEBA==",
},
content_length=len(media),
Expand Down
2 changes: 1 addition & 1 deletion tests/test_proto2rest.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ def test_default_object_access_control_as_rest(self):

def test_object_as_rest(self):
media = b"The quick brown fox jumps over the lazy dog"
# These checksums can be obtained using `gsutil hash`
# These checksums can be obtained using `gcloud storage hash`
crc32c = "ImIEBA=="
md5 = "nhB9nTcrtoJr2B01QqQZ1g=="
object = storage_pb2.Object(
Expand Down
Loading