Skip to content

Speed up a test #46547

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

Closed
wants to merge 1 commit into from
Closed

Speed up a test #46547

wants to merge 1 commit into from

Conversation

jonashaag
Copy link
Contributor

Saves 30s of test time, it ain't much but it's honest work :-) Also moves a magic number to a constant.

  • closes #xxxx (Replace xxxx with the Github issue number)
  • Tests added and passed if fixing a bug or adding a new feature
  • All code checks passed.
  • Added an entry in the latest doc/source/whatsnew/vX.X.X.rst file if fixing a bug or adding a new feature.

@@ -759,9 +759,11 @@ def test_to_csv_chunking(self, chunksize):
tm.assert_frame_equal(rs, aa)

@pytest.mark.slow
def test_to_csv_wide_frame_formatting(self):
def test_to_csv_wide_frame_formatting(self, monkeypatch):
Copy link
Contributor

@jreback jreback Mar 28, 2022

Choose a reason for hiding this comment

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

this is a specific regression test #8621

i dont' think changing this is actually helping. (sure it helps in the running of the test but breaks the regression checking).

@jreback jreback added Testing pandas testing functions or related to the test suite IO CSV read_csv, to_csv labels Mar 28, 2022
@jreback jreback added this to the No action milestone Mar 28, 2022
@jreback jreback closed this Mar 28, 2022
@jreback
Copy link
Contributor

jreback commented Mar 28, 2022

thanks @jonashaag all for faster tests, but we also cannot change them like this (which doesn't really test much). I basically am always -1 on monkey patching as it 99% of the time doesnt' catch anything.

@jonashaag
Copy link
Contributor Author

Actually my version of the test fails before the #8621 fix, I double checked. So it actually tests the bug, just with a smaller number

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
IO CSV read_csv, to_csv 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