Skip to content

Commit eaba0ba

Browse files
committed
fix more test import failures
1 parent 4088fb3 commit eaba0ba

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tests/system/test_gbq.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ def test_read_gbq_raises_invalid_column_order(self, project_id):
195195
col_order = ["string_aaa", "string_1", "string_2"]
196196

197197
# Column string_aaa does not exist. Should raise InvalidColumnOrder
198-
with pytest.raises(gbq.InvalidColumnOrder):
198+
with pytest.raises(exceptions.InvalidColumnOrder):
199199
gbq.read_gbq(
200200
query,
201201
project_id=project_id,
@@ -227,7 +227,7 @@ def test_read_gbq_raises_invalid_index_column(self, project_id):
227227
col_order = ["string_3", "string_2"]
228228

229229
# Column string_bbb does not exist. Should raise InvalidIndexColumn
230-
with pytest.raises(gbq.InvalidIndexColumn):
230+
with pytest.raises(exceptions.InvalidIndexColumn):
231231
gbq.read_gbq(
232232
query,
233233
project_id=project_id,
@@ -507,7 +507,7 @@ def test_timeout_configuration(self, project_id):
507507
]
508508

509509
for config in configs:
510-
with pytest.raises(gbq.QueryTimeout):
510+
with pytest.raises(exceptions.QueryTimeout):
511511
gbq.read_gbq(
512512
sql_statement,
513513
project_id=project_id,
@@ -741,7 +741,7 @@ def test_upload_data_if_table_exists_fail(self, project_id):
741741
)
742742

743743
# Test the default value of if_exists == 'fail'
744-
with pytest.raises(gbq.TableCreationError):
744+
with pytest.raises(exceptions.TableCreationError):
745745
gbq.to_gbq(
746746
df,
747747
self.destination_table + test_id,
@@ -750,7 +750,7 @@ def test_upload_data_if_table_exists_fail(self, project_id):
750750
)
751751

752752
# Test the if_exists parameter with value 'fail'
753-
with pytest.raises(gbq.TableCreationError):
753+
with pytest.raises(exceptions.TableCreationError):
754754
gbq.to_gbq(
755755
df,
756756
self.destination_table + test_id,
@@ -1193,7 +1193,7 @@ def test_create_dataset(bigquery_client, gbq_dataset, random_dataset_id, project
11931193

11941194
def test_create_dataset_already_exists(gbq_dataset, random_dataset_id):
11951195
gbq_dataset.create(random_dataset_id)
1196-
with pytest.raises(gbq.DatasetCreationError):
1196+
with pytest.raises(exceptions.DatasetCreationError):
11971197
gbq_dataset.create(random_dataset_id)
11981198

11991199

@@ -1218,7 +1218,7 @@ def test_create_table(gbq_table):
12181218
def test_create_table_already_exists(gbq_table):
12191219
schema = gbq._generate_bq_schema(make_mixed_dataframe_v1())
12201220
gbq_table.create("test_create_table_exists", schema)
1221-
with pytest.raises(gbq.TableCreationError):
1221+
with pytest.raises(exceptions.TableCreationError):
12221222
gbq_table.create("test_create_table_exists", schema)
12231223

12241224

0 commit comments

Comments
 (0)