Skip to content

Commit d75f89d

Browse files
fix repr tests
1 parent 220960f commit d75f89d

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

pandas/tests/series/test_formats.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ def test_categorical_repr(self, using_infer_string):
314314
"0 a\n1 b\n"
315315
" ..\n"
316316
"48 a\n49 b\n"
317-
"Length: 50, dtype: category\nCategories (2, string): [a, b]"
317+
"Length: 50, dtype: category\nCategories (2, str): [a, b]"
318318
)
319319
else:
320320
exp = (
@@ -332,7 +332,7 @@ def test_categorical_repr(self, using_infer_string):
332332
exp = (
333333
"0 a\n1 b\n"
334334
"dtype: category\n"
335-
"Categories (26, string): [a < b < c < d ... w < x < y < z]"
335+
"Categories (26, str): [a < b < c < d ... w < x < y < z]"
336336
)
337337
else:
338338
exp = (

pandas/tests/util/test_assert_frame_equal.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ def test_frame_equal_index_mismatch(check_like, frame_or_series, using_infer_str
134134
@pytest.mark.parametrize("check_like", [True, False])
135135
def test_frame_equal_columns_mismatch(check_like, frame_or_series, using_infer_string):
136136
if using_infer_string:
137-
dtype = "string"
137+
dtype = "str"
138138
else:
139139
dtype = "object"
140140
msg = f"""{frame_or_series.__name__}\\.columns are different

pandas/tests/util/test_assert_series_equal.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,9 +220,9 @@ def test_series_equal_categorical_values_mismatch(rtol, using_infer_string):
220220
Series values are different \\(66\\.66667 %\\)
221221
\\[index\\]: \\[0, 1, 2\\]
222222
\\[left\\]: \\['a', 'b', 'c'\\]
223-
Categories \\(3, string\\): \\[a, b, c\\]
223+
Categories \\(3, str\\): \\[a, b, c\\]
224224
\\[right\\]: \\['a', 'c', 'b'\\]
225-
Categories \\(3, string\\): \\[a, b, c\\]"""
225+
Categories \\(3, str\\): \\[a, b, c\\]"""
226226
else:
227227
msg = """Series are different
228228

0 commit comments

Comments
 (0)