-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
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
TST: GH30999 Add match=msg to all "with pytest.raises" in pandas/tests/io/pytables/test_store.py #38609
TST: GH30999 Add match=msg to all "with pytest.raises" in pandas/tests/io/pytables/test_store.py #38609
Conversation
…ts/io/pytables/test_store.py
…ts/io/pytables/test_store.py
…ytables_test_store' into add_match_msg_to_pytest_raises_pytables_test_store # Conflicts: # pandas/tests/io/pytables/test_store.py
I can't figure out what went wrong with the Travis CI build. Any hints from anyone would be appreciated. |
ignore it, giving us trouble. |
@moink can you merge master and ping on green (or greenish if the travis build fails like that again). |
OT: @moink love to split this file up: pandas/tests/io/pytables/test_store.py in a separate PR :-> |
thanks @moink very nice |
I agree - I noted that when I made these changes I pushed I am not actually knowledgeable about PyTables and I suspect wouldn't be the best person to do this task. Would you like me to create a new issue? |
you can create a new issue but splitting the tests first is much easier just for visibility |
…s/io/pytables/test_store.py (pandas-dev#38609)
This pull request xref #30999 to remove bare
pytest.raises
. It doesn't close that issue as I have only addressed one file:pandas/tests/io/pytables/test_store.py
. In that file there were 80 instances of barepytest.raises
.test_append_to_multiple_dropna_false
is marked as failing because it isn't raising theValueError
that it should. Because of this, I didn't know what the message should be, and reading through the code didn't help me figure it out. I wrote a draft error message and added aTODO
(line 3790) and I hope that's the best way to handle it.In
test_multiple_open_close
there were several assertions thatClosedFileError
is raised with the same error message, with one in the middle that asserts that anAttributeError
is raised with a different error message. I moved the one for theAttributeError
to the end of the list (line 4229) to organize the assertions a little better and make clear that themsg
parameter is the same for all theClosedFileError
s.I did not add a whatsnew entry since it only changes the tests. Let me know if I should add one (and I am a bit unclear on how, i.e. what version this would end up in).
black pandas
git diff upstream/master -u -- "*.py" | flake8 --diff