Skip to content

ENH: GH-35611 Tests for top-level Pandas functions serializable #35692

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
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions pandas/tests/test_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

import pandas as pd
from pandas import Series, Timestamp
import pandas._testing as tm
from pandas.core import ops
import pandas.core.common as com

Expand Down Expand Up @@ -157,3 +158,10 @@ def test_version_tag():
raise ValueError(
"No git tags exist, please sync tags between upstream and your repo"
)


def test_serializable():
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 parameterize the test on these instead or inside

also pls add the issue number here as a comment

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I understand. I'll do that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jreback Could you take a look of this?

for name, obj in pd.__dict__.items():
if callable(obj):
unpickled = tm.round_trip_pickle(obj)
assert type(obj) == type(unpickled)