-
Notifications
You must be signed in to change notification settings - Fork 605
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
Fix jobs/tests/test_models.py misusing assertTrue
#1987
Fix jobs/tests/test_models.py misusing assertTrue
#1987
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.
LGTM
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.
Sorry. Not a full-time contributor. At least I had an approve button ;-)
assertTrue
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.
This is a valid fix, and a straightforward change.
Here's some others, found using https://github.com/isidentical/teyit.
diff --git a/downloads/tests/test_models.py b/downloads/tests/test_models.py
index f27e951..d31afae 100644
--- a/downloads/tests/test_models.py
+++ b/downloads/tests/test_models.py
@@ -82,8 +82,8 @@ class DownloadModelTests(BaseDownloadTests):
release_38 = Release.objects.create(name='Python 3.8.0')
self.assertFalse(release_38.is_version_at_least_3_9)
- self.assert_(release_38.is_version_at_least_3_5)
+ self.assertTrue(release_38.is_version_at_least_3_5)
release_310 = Release.objects.create(name='Python 3.10.0')
- self.assert_(release_310.is_version_at_least_3_9)
- self.assert_(release_310.is_version_at_least_3_5)
+ self.assertTrue(release_310.is_version_at_least_3_9)
+ self.assertTrue(release_310.is_version_at_least_3_5) |
will merge after #2520 settles |
Fixes #1986