Skip to content

Commit 95cb745

Browse files
authored
Merge branch 'pandas-dev:main' into series-sum-attrs
2 parents 311b662 + f1441b2 commit 95cb745

File tree

2 files changed

+12
-15
lines changed

2 files changed

+12
-15
lines changed

doc/source/user_guide/gotchas.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,5 +372,5 @@ constructors using something similar to the following:
372372
s = pd.Series(newx)
373373
374374
See `the NumPy documentation on byte order
375-
<https://numpy.org/doc/stable/user/basics.byteswapping.html>`__ for more
375+
<https://numpy.org/doc/stable/user/byteswapping.html>`__ for more
376376
details.

pandas/tests/io/formats/test_to_string.py

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -132,20 +132,17 @@ def test_to_string_with_formatters_unicode(self):
132132
)
133133
assert result == expected
134134

135-
def test_to_string_index_formatter(self):
136-
df = DataFrame([range(5), range(5, 10), range(10, 15)])
137-
138-
rs = df.to_string(formatters={"__index__": lambda x: "abc"[x]})
139-
140-
xp = dedent(
141-
"""\
142-
0 1 2 3 4
143-
a 0 1 2 3 4
144-
b 5 6 7 8 9
145-
c 10 11 12 13 14\
146-
"""
147-
)
148-
assert rs == xp
135+
def test_to_string_index_formatter(self):
136+
df = DataFrame([range(5), range(5, 10), range(10, 15)])
137+
rs = df.to_string(formatters={"__index__": lambda x: "abc"[x]})
138+
xp = dedent(
139+
"""\
140+
0 1 2 3 4
141+
a 0 1 2 3 4
142+
b 5 6 7 8 9
143+
c 10 11 12 13 14"""
144+
)
145+
assert rs == xp
149146

150147
def test_no_extra_space(self):
151148
# GH#52690: Check that no extra space is given

0 commit comments

Comments
 (0)