Skip to content

TST: parametrize and improve test performance #55962

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
Nov 16, 2023

Conversation

mroeschke
Copy link
Member

No description provided.

@mroeschke mroeschke added the Testing pandas testing functions or related to the test suite label Nov 14, 2023
df = DataFrame([{f"foo_{i}": f"bar_{i}" for i in range(limit)}])
result = next(df.itertuples(index=index))
assert isinstance(result, tuple)
assert hasattr(result, "_fields")
Copy link
Member

Choose a reason for hiding this comment

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

is this a kludgy way of checking for a NamedTuple?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think so, yes (these are also fairly old test)

@mroeschke mroeschke added this to the 2.2 milestone Nov 15, 2023
@mroeschke
Copy link
Member Author

Going to merge. Happy to follow up if needed

@mroeschke mroeschke merged commit 7e89905 into pandas-dev:main Nov 16, 2023
@mroeschke mroeschke deleted the tst/perf branch November 16, 2023 17:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Testing pandas testing functions or related to the test suite
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants