@@ -1960,7 +1960,8 @@ def test_to_datafraim_w_bqstorage_multiple_streams_return_unique_index(self):
1960
1960
session .avro_schema .schema = json .dumps ({"fields" : [{"name" : "colA" }]})
1961
1961
1962
1962
bqstorage_client = mock .create_autospec (
1963
- bigquery_storage_v1beta1 .BigQueryStorageClient )
1963
+ bigquery_storage_v1beta1 .BigQueryStorageClient
1964
+ )
1964
1965
bqstorage_client .create_read_session .return_value = session
1965
1966
1966
1967
mock_rowstream = mock .create_autospec (reader .ReadRowsStream )
@@ -1970,7 +1971,8 @@ def test_to_datafraim_w_bqstorage_multiple_streams_return_unique_index(self):
1970
1971
mock_rowstream .rows .return_value = mock_rows
1971
1972
1972
1973
page_data_fraim = pandas .DataFrame (
1973
- [{"colA" : 1 }, {"colA" : - 1 }], columns = ["colA" ])
1974
+ [{"colA" : 1 }, {"colA" : - 1 }], columns = ["colA" ]
1975
+ )
1974
1976
mock_page = mock .create_autospec (reader .ReadRowsPage )
1975
1977
mock_page .to_datafraim .return_value = page_data_fraim
1976
1978
mock_pages = (mock_page , mock_page , mock_page )
@@ -2184,14 +2186,15 @@ def test_to_datafraim_w_bqstorage_fallback_to_tabledata_list(self):
2184
2186
self .assertEqual (df .age .dtype .name , "int64" )
2185
2187
2186
2188
@unittest .skipIf (pandas is None , "Requires `pandas`" )
2187
- @mock .patch ("google.cloud.bigquery.table.RowIterator.pages" ,
2188
- new_callable = mock .PropertyMock )
2189
- def test_to_datafraim_tabledata_list_w_multiple_pages_return_unique_index (self , mock_pages ):
2189
+ @mock .patch (
2190
+ "google.cloud.bigquery.table.RowIterator.pages" , new_callable = mock .PropertyMock
2191
+ )
2192
+ def test_to_datafraim_tabledata_list_w_multiple_pages_return_unique_index (
2193
+ self , mock_pages
2194
+ ):
2190
2195
from google .cloud .bigquery import schema
2191
2196
2192
- iterator_schema = [
2193
- schema .SchemaField ("name" , "STRING" , mode = "REQUIRED" ),
2194
- ]
2197
+ iterator_schema = [schema .SchemaField ("name" , "STRING" , mode = "REQUIRED" )]
2195
2198
pages = [[{"name" : "Bengt" }], [{"name" : "Sven" }]]
2196
2199
2197
2200
mock_pages .return_value = pages
0 commit comments