Skip to content

Commit

Permalink
fix: add timeouts to unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tswast committed Dec 11, 2019
1 parent f499e7e commit c10002e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
12 changes: 10 additions & 2 deletions bigquery/tests/unit/test__http.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,11 @@ def test_user_agent(self):
}
expected_uri = conn.build_api_url("/rainbow")
http.request.assert_called_once_with(
data=req_data, headers=expected_headers, method="GET", url=expected_uri
data=req_data,
headers=expected_headers,
method="GET",
url=expected_uri,
timeout=None,
)
self.assertIn("my-application/1.2.3", conn.user_agent)

Expand Down Expand Up @@ -104,5 +108,9 @@ def test_extra_headers_replace(self):
}
expected_uri = conn.build_api_url("/rainbow")
http.request.assert_called_once_with(
data=req_data, headers=expected_headers, method="GET", url=expected_uri
data=req_data,
headers=expected_headers,
method="GET",
url=expected_uri,
timeout=None,
)
1 change: 1 addition & 0 deletions bigquery/tests/unit/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1552,6 +1552,7 @@ def test_get_table_sets_user_agent(self):
"User-Agent": expected_user_agent,
},
data=mock.ANY,
timeout=None,
)
self.assertIn("my-application/1.2.3", expected_user_agent)

Expand Down

0 comments on commit c10002e

Please sign in to comment.