Skip to content

Commit 548b501

Browse files
fix test for str on current main
1 parent 8b92517 commit 548b501

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

pandas/tests/arrays/test_array.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
import numpy as np
66
import pytest
77

8+
from pandas._config import using_string_dtype
9+
810
import pandas as pd
911
import pandas._testing as tm
1012
from pandas.api.extensions import register_extension_dtype
@@ -218,7 +220,9 @@ def test_dt64_array(dtype_unit):
218220
"str",
219221
pd.StringDtype(na_value=np.nan)
220222
.construct_array_type()
221-
._from_sequence(["a", None], dtype=pd.StringDtype(na_value=np.nan)),
223+
._from_sequence(["a", None], dtype=pd.StringDtype(na_value=np.nan))
224+
if using_string_dtype()
225+
else NumpyExtensionArray(np.array(["a", "None"])),
222226
),
223227
(
224228
["a", None],

0 commit comments

Comments
 (0)