Skip to content

Commit

Permalink
test: fix operator priority (googleapis#411)
Browse files Browse the repository at this point in the history
At least with my version of Python (3.10.7) these tests did not pass.
  • Loading branch information
coryan committed Oct 3, 2022
1 parent 4ddb285 commit b5e490a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions tests/test_testbench_object_upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ def test_upload_resumable_x_upload_content_length(self):
"/upload/storage/v1/b/bucket-name/o",
query_string={"uploadType": "resumable", "name": "zebra"},
content_type="application/json",
headers={"x-upload-content-length": "%d" % 2 * len(chunk)},
headers={"x-upload-content-length": "%d" % (2 * len(chunk))},
data=json.dumps({"name": "zebra", "metadata": {"key0": "label0"}}),
)
self.assertEqual(response.status_code, 200)
Expand All @@ -257,7 +257,7 @@ def test_upload_resumable_x_upload_content_length(self):
query_string={"upload_id": upload_id},
headers={
"content-range": "bytes 0-{last:d}/*".format(last=len(chunk) - 1),
"x-upload-content-length": "%d" % 2 * len(chunk),
"x-upload-content-length": "%d" % (2 * len(chunk)),
},
data=chunk,
)
Expand Down
4 changes: 2 additions & 2 deletions tests/test_testbench_retry.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ def test_retry_test_return_no_metadata_on_resumable_multi_chunk_complete(self):
"/upload/storage/v1/b/bucket-name/o",
query_string={"uploadType": "resumable", "name": "256kobject"},
headers={
"x-upload-content-length": "%d" % 2 * len(chunk),
"x-upload-content-length": "%d" % (2 * len(chunk)),
"x-retry-test-id": id,
},
)
Expand All @@ -314,7 +314,7 @@ def test_retry_test_return_no_metadata_on_resumable_multi_chunk_complete(self):
location,
headers={
"content-range": "bytes 0-{last:d}/*".format(last=len(chunk) - 1),
"x-upload-content-length": "%d" % 2 * len(chunk),
"x-upload-content-length": "%d" % (2 * len(chunk)),
"x-retry-test-id": id,
},
data=chunk,
Expand Down

0 comments on commit b5e490a

Please sign in to comment.