You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been finding myself copy-and-pasting quite a lot when making tests, and I think we could use more helpers along the lines of URLsMixinBase and its descendants.
We could use:
Mixins for testing forms, including crispy_forms.
Mixins for testing API views, especially ones built from viewsets, which have a standard setup and are the most egregiously copy-and-paste-heavy. Being able to use mixins in order to test a series of views for a particular model in just a few concise lines would be lovely.
Mixins for testing serializers. These are also quite copy-and-paste-heavy, and long-winded with it.
Mixins for basic model tests, ideally asserting str() and fields.
Having basic TestCases for all of these mixins (like URLsTestCaseREST) would also be stellar. I think we could save a lot of time and tedium by refactoring our tests now.
@incuna/backend thoughts/suggestions for more test mixins?
The text was updated successfully, but these errors were encountered:
I've been finding myself copy-and-pasting quite a lot when making tests, and I think we could use more helpers along the lines of URLsMixinBase and its descendants.
We could use:
str()
and fields.Having basic TestCases for all of these mixins (like URLsTestCaseREST) would also be stellar. I think we could save a lot of time and tedium by refactoring our tests now.
@incuna/backend thoughts/suggestions for more test mixins?
The text was updated successfully, but these errors were encountered: