Skip to content

Commit 7698f5a

Browse files
committed
fix: skip test__bqschema_to_nullsafe_dtypes for pandas < 2.0.0
1 parent 99b0113 commit 7698f5a

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

tests/unit/test_gbq.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,11 +113,16 @@ def test__bqschema_to_nullsafe_dtypes(type_, expected):
113113
assert result == {"x": expected}
114114

115115

116+
@pytest.mark.skipif(
117+
pandas.__version__ < "2.0.0", reason="requires pandas 2.0.0 or higher"
118+
)
116119
@pytest.mark.parametrize(
117120
("data", "schema_type", "expected"),
118121
[
119122
(
120-
pandas.to_datetime(["2017-01-01T12:00:00Z"]).astype(pandas.DatetimeTZDtype(unit="us", tz="UTC")),
123+
pandas.to_datetime(["2017-01-01T12:00:00Z"]).astype(
124+
pandas.DatetimeTZDtype(unit="us", tz="UTC")
125+
),
121126
"TIMESTAMP",
122127
pandas.DatetimeTZDtype(unit="us", tz="UTC"),
123128
),

0 commit comments

Comments
 (0)