@@ -67,8 +67,13 @@ def test_initialize_readonly(self, mock_build, mock_return_cred):
6767 scopes = BIGQUERY_SCOPE_READ_ONLY )
6868 self .assertTrue (
6969 mock_cred .from_p12_keyfile_buffer .return_value .authorize .called )
70- mock_build .assert_called_once_with ('bigquery' , 'v2' , http = mock_http ,
71- discoveryServiceUrl = mock_service_url )
70+ mock_build .assert_called_once_with (
71+ 'bigquery' ,
72+ 'v2' ,
73+ http = mock_http ,
74+ discoveryServiceUrl = mock_service_url ,
75+ cache_discovery = False
76+ )
7277 self .assertEquals (mock_bq , bq_client .bigquery )
7378 self .assertEquals (project_id , bq_client .project_id )
7479
@@ -101,8 +106,13 @@ def test_initialize_read_write(self, mock_build, mock_return_cred):
101106 service_account , mock .ANY , scopes = BIGQUERY_SCOPE )
102107 self .assertTrue (
103108 mock_cred .from_p12_keyfile_buffer .return_value .authorize .called )
104- mock_build .assert_called_once_with ('bigquery' , 'v2' , http = mock_http ,
105- discoveryServiceUrl = mock_service_url )
109+ mock_build .assert_called_once_with (
110+ 'bigquery' ,
111+ 'v2' ,
112+ http = mock_http ,
113+ discoveryServiceUrl = mock_service_url ,
114+ cache_discovery = False
115+ )
106116 self .assertEquals (mock_bq , bq_client .bigquery )
107117 self .assertEquals (project_id , bq_client .project_id )
108118
@@ -136,8 +146,13 @@ def test_initialize_key_file(self, mock_build, mock_return_cred):
136146 scopes = BIGQUERY_SCOPE )
137147 self .assertTrue (
138148 mock_cred .from_p12_keyfile .return_value .authorize .called )
139- mock_build .assert_called_once_with ('bigquery' , 'v2' , http = mock_http ,
140- discoveryServiceUrl = mock_service_url )
149+ mock_build .assert_called_once_with (
150+ 'bigquery' ,
151+ 'v2' ,
152+ http = mock_http ,
153+ discoveryServiceUrl = mock_service_url ,
154+ cache_discovery = False
155+ )
141156 self .assertEquals (mock_bq , bq_client .bigquery )
142157 self .assertEquals (project_id , bq_client .project_id )
143158
@@ -172,8 +187,13 @@ def test_initialize_json_key_file(self, mock_open, mock_build, mock_return_cred)
172187 scopes = BIGQUERY_SCOPE )
173188 self .assertTrue (
174189 mock_cred .from_json_keyfile_dict .return_value .authorize .called )
175- mock_build .assert_called_once_with ('bigquery' , 'v2' , http = mock_http ,
176- discoveryServiceUrl = mock_service_url )
190+ mock_build .assert_called_once_with (
191+ 'bigquery' ,
192+ 'v2' ,
193+ http = mock_http ,
194+ discoveryServiceUrl = mock_service_url ,
195+ cache_discovery = False
196+ )
177197 self .assertEquals (mock_bq , bq_client .bigquery )
178198 self .assertEquals (project_id , bq_client .project_id )
179199
@@ -208,8 +228,13 @@ def test_initialize_json_key_file_without_project_id(self, mock_open, mock_build
208228 scopes = BIGQUERY_SCOPE )
209229 self .assertTrue (
210230 mock_cred .from_json_keyfile_dict .return_value .authorize .called )
211- mock_build .assert_called_once_with ('bigquery' , 'v2' , http = mock_http ,
212- discoveryServiceUrl = mock_service_url )
231+ mock_build .assert_called_once_with (
232+ 'bigquery' ,
233+ 'v2' ,
234+ http = mock_http ,
235+ discoveryServiceUrl = mock_service_url ,
236+ cache_discovery = False
237+ )
213238 self .assertEquals (mock_bq , bq_client .bigquery )
214239 self .assertEquals (json_key ['project_id' ], bq_client .project_id )
215240
0 commit comments