Skip to content

TST: Check float format in object column (#35603) #41668

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
May 27, 2021
9 changes: 9 additions & 0 deletions pandas/tests/series/test_repr.py
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,15 @@ def test_series_repr_nat(self):
)
assert result == expected

def test_float_repr_in_frame(self):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you remove _in_frame (as this a series).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, sure.

# GH#35603
# check float format when cast to object
ser = Series([1.0]).astype(object)
expected = (
"0 1.0\n"
"dtype: object"
)
assert repr(ser) == expected

class TestCategoricalRepr:
def test_categorical_repr_unicode(self):
Expand Down