-
Notifications
You must be signed in to change notification settings - Fork 7k
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
Port test/test_datasets.py to use pytest #4215
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @sallysyw , contrags on your first torchvision PR!
This looks great, there are just 2 assertions that need a minor change. I'll approve anyway, feel free to self-merge once the changes are addressed
Indeed the next step will be to fully remove the use of It'd be nice to change the |
Hey @sallysyw! You merged this PR, but no labels were added. |
IIRC, you can't use Lines 387 to 392 in b29ed34
which we would have to emulate another way. |
That's correct, and getting rid of |
Summary: * Port test_datasets.py to use pytest * A better replacement of self.assertSequenceEqual * Migrate from equality check to identity check Reviewed By: NicolasHug Differential Revision: D30069955 fbshipit-source-id: 0f86c15f1457d1bcf21a4c634b0a70e256a804f5
Following the discussion in #3945, we should also port
test/test_dataset
to usepytest
.In this PR, we replace all the
self.assertXYZ
with pythonassert
.TODO: Replace the
self.subTest()
in these files and finally remove theunittest.TestCase
inheritance.