-
Notifications
You must be signed in to change notification settings - Fork 7.2k
Port tests in test_transforms_video.py to pytest #4040
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 tests in test_transforms_video.py to pytest #4040
Conversation
test/test_transforms_video.py
Outdated
msg = "height: " + str(height) + " width: " \ | ||
+ str(width) + " oheight: " + str(oheight) + " owidth: " + str(owidth) | ||
self.assertEqual(sum1.item() > 1, True, msg) | ||
assert sum1.item() > 1 == True, msg |
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.
flake
test here suggests:
./test/test_transforms_video.py:85:32: E712 comparison to True should be 'if cond is True:' or 'if cond:'
Do I need to change or stick with the original implementation?
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.
Yes we should just use assert sum1.item() > 1, msg
:)
8ed0529
to
5006659
Compare
Thanks @DevPranjal !! |
Thanks for the fix. |
Reviewed By: fmassa Differential Revision: D29097720 fbshipit-source-id: fe2afb61e2a5ea23f467793dd33f545435d4db26
Refactor test_transforms_video.py to pytest as mentioned in #4033