Skip to content
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

BigQuery: Fix BigQuery client unit test assertions #9112

Merged
merged 1 commit into from
Aug 27, 2019
Merged
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: 3 additions & 1 deletion bigquery/tests/unit/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -3110,6 +3110,7 @@ def _initiate_resumable_upload_helper(self, num_retries=None):
upload_url,
data=json.dumps(metadata).encode("utf-8"),
headers=request_headers,
timeout=mock.ANY,
)

def test__initiate_resumable_upload(self):
Expand Down Expand Up @@ -3162,7 +3163,7 @@ def _do_multipart_upload_success_helper(self, get_boundary, num_retries=None):
headers = _get_upload_headers(conn.user_agent)
headers["content-type"] = b'multipart/related; boundary="==0=="'
fake_transport.request.assert_called_once_with(
"POST", upload_url, data=payload, headers=headers
"POST", upload_url, data=payload, headers=headers, timeout=mock.ANY
)

@mock.patch(u"google.resumable_media._upload.get_boundary", return_value=b"==0==")
Expand Down Expand Up @@ -5896,6 +5897,7 @@ def test__do_resumable_upload(self):
mock.ANY,
data=json.dumps(self.EXPECTED_CONFIGURATION).encode("utf-8"),
headers=mock.ANY,
timeout=mock.ANY,
)

def test__do_multipart_upload(self):
Expand Down